Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
50.00% |
1 / 2 |
|
50.00% |
1 / 2 |
CRAP | |
0.00% |
0 / 1 |
| IsTopLevelDomain | |
50.00% |
1 / 2 |
|
50.00% |
1 / 2 |
2.50 | |
0.00% |
0 / 1 |
| getData | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
| isActive | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
2 | |||
| 1 | <?php |
| 2 | namespace Apie\IanaValueObjects\TopLevelDomain; |
| 3 | |
| 4 | use Apie\IanaValueObjects\IsSanitizingInput; |
| 5 | use Apie\IanaValueObjects\StaticDataValueObject; |
| 6 | |
| 7 | trait IsTopLevelDomain |
| 8 | { |
| 9 | use StaticDataValueObject, IsSanitizingInput { |
| 10 | IsSanitizingInput::convert insteadof StaticDataValueObject; |
| 11 | } |
| 12 | |
| 13 | protected static function getData(): array |
| 14 | { |
| 15 | return require __DIR__ . '/../../fixtures/tlds.php'; |
| 16 | } |
| 17 | |
| 18 | public function isActive(): bool |
| 19 | { |
| 20 | return (bool) $this->getFieldValue('Active'); |
| 21 | } |
| 22 | } |