blib/lib/ODS/Storage/File/YAML.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
statement | 10 | 10 | 100.0 |
branch | n/a | ||
condition | n/a | ||
subroutine | 4 | 4 | 100.0 |
pod | 0 | 2 | 0.0 |
total | 14 | 16 | 87.5 |
line | stmt | bran | cond | sub | pod | time | code |
---|---|---|---|---|---|---|---|
1 | package ODS::Storage::File::YAML; | ||||||
2 | |||||||
3 | 1 | 1 | 6 | use YAOO; | |||
1 | 1 | ||||||
1 | 5 | ||||||
4 | 1 | 1 | 620 | use YAML::XS; | |||
1 | 2305 | ||||||
1 | 117 | ||||||
5 | |||||||
6 | extends 'ODS::Storage::File'; | ||||||
7 | |||||||
8 | has file_suffix => isa(string('yml')); | ||||||
9 | |||||||
10 | sub parse_data_format { | ||||||
11 | 2 | 2 | 0 | 4 | my ($self, $data) = @_; | ||
12 | 2 | 132 | return Load $data; | ||||
13 | } | ||||||
14 | |||||||
15 | sub stringify_data_format { | ||||||
16 | 6 | 6 | 0 | 13 | my ($self, $data) = @_; | ||
17 | 6 | 368 | return Dump $data; | ||||
18 | } | ||||||
19 | |||||||
20 | 1; |