Code Coverage |
||||||||||
Classes and Traits |
Functions and Methods |
Lines |
||||||||
| Total | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
CRAP | |
100.00% |
1 / 1 |
| Caesar | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |
100.00% |
1 / 1 |
| isLeapYear | |
100.00% |
1 / 1 |
1 | |
100.00% |
1 / 1 |
|||
| <?php | |
| namespace Popy\Calendar\Converter\LeapYearCalculator; | |
| use Popy\Calendar\Converter\SimpleLeapYearCalculatorInterface; | |
| /** | |
| * Julius Caesar implementation (julian calendar way). Imprecise, but that's | |
| * not somebody you should mess with. | |
| */ | |
| class Caesar implements SimpleLeapYearCalculatorInterface | |
| { | |
| /** | |
| * @inheritDoc | |
| */ | |
| public function isLeapYear($year) | |
| { | |
| return !($year % 4); | |
| } | |
| } |