@@ 30-54 (lines=25) @@ | ||
27 | */ |
|
28 | protected $stub; |
|
29 | ||
30 | public function setUp() |
|
31 | { |
|
32 | parent::setUp(); |
|
33 | ||
34 | $this->stub = new CompletePurchaseRequestStub(); |
|
35 | $stub = $this->stub; |
|
36 | ||
37 | $httpRequest = new HttpRequest([], [ |
|
38 | 'ik_co_id' => $stub->purse, |
|
39 | 'ik_trn_id' => $stub->transactionId, |
|
40 | 'ik_desc' => $stub->description, |
|
41 | 'ik_am' => $stub->amount, |
|
42 | 'ik_cur' => $stub->currency, |
|
43 | 'ik_inv_prc' => $stub->time, |
|
44 | 'ik_sign' => $stub->sign, |
|
45 | 'ik_inv_st' => $stub->state, |
|
46 | ]); |
|
47 | ||
48 | $this->request = new CompletePurchaseRequest($this->getHttpClient(), $httpRequest); |
|
49 | $this->request->initialize([ |
|
50 | 'purse' => $stub->purse, |
|
51 | 'signAlgorithm' => $stub->signAlgorithm, |
|
52 | 'signKey' => $stub->signKey, |
|
53 | ]); |
|
54 | } |
|
55 | ||
56 | public function testGetData() |
|
57 | { |
@@ 29-51 (lines=23) @@ | ||
26 | */ |
|
27 | protected $stub; |
|
28 | ||
29 | public function setUp() |
|
30 | { |
|
31 | parent::setUp(); |
|
32 | ||
33 | $stub = $this->stub = new OldCompletePurchaseRequestStub(); |
|
34 | ||
35 | $httpRequest = new HttpRequest([], [ |
|
36 | 'ik_shop_id' => $stub->purse, |
|
37 | 'ik_payment_id' => $stub->transactionId, |
|
38 | 'ik_payment_desc' => $stub->description, |
|
39 | 'ik_payment_amount' => $stub->amount, |
|
40 | 'ik_payment_timestamp' => $stub->time, |
|
41 | 'ik_sign_hash' => $stub->sign, |
|
42 | 'ik_payment_state' => $stub->state, |
|
43 | ]); |
|
44 | ||
45 | $this->request = new OldCompletePurchaseRequest($this->getHttpClient(), $httpRequest); |
|
46 | $this->request->initialize([ |
|
47 | 'purse' => $stub->purse, |
|
48 | 'signAlgorithm' => $stub->signAlgorithm, |
|
49 | 'signKey' => $stub->signKey, |
|
50 | ]); |
|
51 | } |
|
52 | ||
53 | public function testGetData() |
|
54 | { |