| Conditions | 1 |
| Paths | 1 |
| Total Lines | 17 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 14 | public function testSerialize() |
||
| 15 | { |
||
| 16 | $ipag = new Ipag(new Authentication('[email protected]')); |
||
| 17 | |||
| 18 | $transaction = $ipag->transaction()->setTid('123456789'); |
||
| 19 | |||
| 20 | $cancelSerializer = new Serializer($transaction, Action::CONSULT, Operation::CONSULT); |
||
| 21 | |||
| 22 | $response = $cancelSerializer->serialize(); |
||
| 23 | |||
| 24 | $expected = [ |
||
| 25 | 'identificacao' => urlencode('[email protected]'), |
||
| 26 | 'transId' => urlencode('123456789'), |
||
| 27 | 'retorno_tipo' => urlencode('xml'), |
||
| 28 | ]; |
||
| 29 | |||
| 30 | $this->assertEquals($expected, $response); |
||
| 31 | } |
||
| 33 |