Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
CRAP
100.00% covered (success)
100.00%
1 / 1
DutchPhoneNumber
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
100.00% covered (success)
100.00%
1 / 1
 fromCountry
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2namespace Apie\CountryAndPhoneNumber;
3
4use Apie\Core\Attributes\Description;
5use Apie\Core\Attributes\ExampleValue;
6use Apie\Core\Attributes\FakeMethod;
7use Apie\CountryAndPhoneNumber\Concerns\CanCreateRandomPhoneNumber;
8use PrinsFrank\Standards\Country\CountryAlpha2;
9
10#[FakeMethod('createRandomInstance')]
11#[Description('A phone number valid in the Netherlands in national format or E164 format')]
12#[ExampleValue('+31612345678')]
13#[ExampleValue('0612345678')]
14class DutchPhoneNumber extends PhoneNumber
15{
16    use CanCreateRandomPhoneNumber;
17
18    public static function fromCountry(): CountryAlpha2
19    {
20        return CountryAlpha2::Netherlands;
21    }
22}