Conditions | 2 |
Paths | 2 |
Total Lines | 25 |
Code Lines | 18 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php declare(strict_types = 1); |
||
11 | public function testFunctionality() |
||
12 | { |
||
13 | if (getenv('TRAVIS') !== false) { |
||
14 | $this->markTestSkipped('EET is blocking Travis CI :('); |
||
15 | } |
||
16 | $crypto = new CryptographyService(__DIR__ . '/../../cert/EET_CA1_Playground-CZ00000019.key', __DIR__ . '/../../cert/EET_CA1_Playground-CZ00000019.pub'); |
||
17 | $configuration = new Configuration('CZ00000019', '273', '/5546/RO24', new EvidenceEnvironment(EvidenceEnvironment::PLAYGROUND), false); |
||
18 | $client = new Client($crypto, $configuration, new GuzzleSoapClientDriver(new \GuzzleHttp\Client())); |
||
19 | |||
20 | $receipt = new Receipt( |
||
21 | true, |
||
22 | 'CZ683555118', |
||
23 | '0/6460/ZQ42', |
||
24 | new \DateTimeImmutable('2016-11-01 00:30:12'), |
||
25 | 3411300 |
||
26 | ); |
||
27 | |||
28 | $response = $client->send($receipt); |
||
29 | |||
30 | $this->assertInstanceOf(EvidenceResponse::class, $response); |
||
31 | $this->assertTrue($response->isValid()); |
||
32 | $this->assertNotNull($response->getFik()); |
||
33 | $this->assertNotNull($response->getUuid()); |
||
34 | $this->assertTrue($response->isTest()); |
||
35 | } |
||
36 | |||
38 |