| blib/lib/App/RecordStream/Accumulator.pm | |||
|---|---|---|---|
| Criterion | Covered | Total | % |
| statement | 8 | 8 | 100.0 |
| branch | n/a | ||
| condition | 2 | 2 | 100.0 |
| subroutine | 3 | 3 | 100.0 |
| pod | 0 | 3 | 0.0 |
| total | 13 | 16 | 81.2 |
| line | stmt | bran | cond | sub | pod | time | code |
|---|---|---|---|---|---|---|---|
| 1 | package App::RecordStream::Accumulator; | ||||||
| 2 | |||||||
| 3 | our $VERSION = "4.0.24"; | ||||||
| 4 | |||||||
| 5 | sub accept_record { | ||||||
| 6 | 359 | 359 | 0 | 498 | my $this = shift; | ||
| 7 | 359 | 591 | $this->accumulate_record(shift); | ||||
| 8 | } | ||||||
| 9 | |||||||
| 10 | sub accumulate_record { | ||||||
| 11 | 359 | 359 | 0 | 492 | my $this = shift; | ||
| 12 | 359 | 481 | push @{$this->get_records()}, shift; | ||||
| 359 | 606 | ||||||
| 13 | } | ||||||
| 14 | |||||||
| 15 | sub get_records { | ||||||
| 16 | 379 | 379 | 0 | 526 | my $this = shift; | ||
| 17 | |||||||
| 18 | 379 | 100 | 761 | $this->{'RECORDS'} ||= []; | |||
| 19 | 379 | 1331 | return $this->{'RECORDS'}; | ||||
| 20 | } | ||||||
| 21 | |||||||
| 22 | 1; |