| Conditions | 1 | 
| Paths | 1 | 
| Total Lines | 17 | 
| Code Lines | 13 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 0 | ||
| 1 | <?php declare(strict_types = 1);  | 
            ||
| 13 | public function testGetCodes()  | 
            ||
| 14 | 	{ | 
            ||
| 15 | $data = [  | 
            ||
| 16 | 'dic_popl' => 'CZ00000019',  | 
            ||
| 17 | 'id_provoz' => '273',  | 
            ||
| 18 | 'id_pokl' => '/5546/RO24',  | 
            ||
| 19 | 'porad_cis' => '0/6460/ZQ42',  | 
            ||
| 20 | 			'dat_trzby' => Formatter::formatDateTime(new \DateTimeImmutable('2016-08-05 00:30:12', new \DateTimeZone('Europe/Prague'))), | 
            ||
| 21 | 'celk_trzba' => Formatter::formatAmount(3411300),  | 
            ||
| 22 | ];  | 
            ||
| 23 | $crypto = new CryptographyService(__DIR__ . '/../../cert/EET_CA1_Playground-CZ00000019.key', __DIR__ . '/../../cert/EET_CA1_Playground-CZ00000019.pub');  | 
            ||
| 24 | |||
| 25 | $expectedPkp = base64_decode(self::EXPECTED_PKP);  | 
            ||
| 26 | $pkpCode = $crypto->getPkpCode($data);  | 
            ||
| 27 | self::assertSame($expectedPkp, $pkpCode);  | 
            ||
| 28 | self::assertSame(self::EXPECTED_BKP, $crypto->getBkpCode($pkpCode));  | 
            ||
| 29 | }  | 
            ||
| 30 | |||
| 32 |