GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Passed
Pull Request — master (#58)
by joseph
17:08
created

AddressEmbeddableTest   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 2
dl 0
loc 27
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A itCanSetAndGetAllTheThings() 0 20 2
1
<?php declare(strict_types=1);
2
3
namespace EdmondsCommerce\DoctrineStaticMeta\Entity\Embeddable\Objects\Geo;
4
5
use EdmondsCommerce\DoctrineStaticMeta\Entity\Embeddable\Interfaces\Objects\Geo\AddressEmbeddableInterface;
6
use PHPUnit\Framework\TestCase;
7
8
class AddressEmbeddableTest extends TestCase
9
{
10
    /**
11
     * @test
12
     * @small
13
     * @covers \EdmondsCommerce\DoctrineStaticMeta\Entity\Embeddable\Objects\Geo\AddressEmbeddable
14
     */
15
    public function itCanSetAndGetAllTheThings()
16
    {
17
        $expected = [
18
            AddressEmbeddableInterface::EMBEDDED_PROP_HOUSE_NUMBER => '1',
19
            AddressEmbeddableInterface::EMBEDDED_PROP_HOUSE_NAME   => 'home',
20
            AddressEmbeddableInterface::EMBEDDED_PROP_STREET       => 'streety street',
21
            AddressEmbeddableInterface::EMBEDDED_PROP_CITY         => 'Bradford',
22
            AddressEmbeddableInterface::EMBEDDED_PROP_POSTAL_AREA  => 'Shipley',
23
            AddressEmbeddableInterface::EMBEDDED_PROP_POSTAL_CODE  => 'BD17 7DB',
24
            AddressEmbeddableInterface::EMBEDDED_PROP_COUNTRY_CODE => 'GBR',
25
        ];
26
        $actual   = [];
27
        $address  = new AddressEmbeddable();
28
        foreach ($expected as $property => $value) {
29
            $setter = "set$property";
30
            $getter = "get$property";
31
            $address->$setter($value);
32
            $actual[$property] = $address->$getter();
33
        }
34
        $this->assertSame($expected, $actual);
35
    }
36
}
37