Code Duplication    Length = 29-29 lines in 2 locations

spec/Model/CallTracking/CallTrackingSpec.php 1 location

@@ 9-37 (lines=29) @@
6
7
use Yproximite\Api\Model\CallTracking\CallTracking;
8
9
class CallTrackingSpec extends ObjectBehavior
10
{
11
    function it_is_initializable()
12
    {
13
        $this->shouldHaveType(CallTracking::class);
14
    }
15
16
    function let()
17
    {
18
        $data = [
19
            'id'               => '11',
20
            'name'             => 'Simple call',
21
            'phoneDid'         => '+1 343 553 22 33',
22
            'phoneDestination' => '+1 233 211 21 77',
23
            'callerId'         => 1,
24
        ];
25
26
        $this->beConstructedWith($data);
27
    }
28
29
    function it_should_be_hydrated()
30
    {
31
        $this->getId()->shouldReturn(11);
32
        $this->getName()->shouldReturn('Simple call');
33
        $this->getPhoneDid()->shouldReturn('+1 343 553 22 33');
34
        $this->getPhoneDestination()->shouldReturn('+1 233 211 21 77');
35
        $this->hasCallerId()->shouldReturn(true);
36
    }
37
}
38

spec/Model/User/UserSpec.php 1 location

@@ 9-37 (lines=29) @@
6
7
use Yproximite\Api\Model\User\User;
8
9
class UserSpec extends ObjectBehavior
10
{
11
    function it_is_initializable()
12
    {
13
        $this->shouldHaveType(User::class);
14
    }
15
16
    function let()
17
    {
18
        $data = [
19
            'id'        => '1',
20
            'firstName' => 'Example',
21
            'lastName'  => '',
22
            'email'     => '[email protected]',
23
            'company'   => '6',
24
        ];
25
26
        $this->beConstructedWith($data);
27
    }
28
29
    function it_should_be_hydrated()
30
    {
31
        $this->getId()->shouldReturn(1);
32
        $this->getFirstName()->shouldReturn('Example');
33
        $this->getLastName()->shouldReturn('');
34
        $this->getEmail()->shouldReturn('[email protected]');
35
        $this->getCompanyId()->shouldReturn(6);
36
    }
37
}
38