| @@ 9-18 (lines=10) @@ | ||
| 6 | ||
| 7 | class LinksTest extends TestCase  | 
                                |
| 8 | { | 
                                |
| 9 | public function testGetLinkWithoutCheckout()  | 
                                |
| 10 |     { | 
                                |
| 11 | $this->sandbox_mock = self::MOCK;  | 
                                |
| 12 | $this->mockHttpSession($this->body_order);  | 
                                |
| 13 | $order = $this->createOrder()->create();  | 
                                |
| 14 | $this->mockHttpSession($this->body_billet_pay);  | 
                                |
| 15 |         $payment = $order->payments()->setBoleto(new \DateTime('today +1day'), 'http://dev.moip.com.br/images/logo-header-moip.png')->execute(); | 
                                |
| 16 | ||
| 17 |         $this->assertEquals('https://checkout-sandbox.moip.com.br/boleto/PAY-XNVIBO5MIQ9S', $payment->getLinks()->getLink('payBoleto')); | 
                                |
| 18 | }  | 
                                |
| 19 | ||
| 20 | public function testGetCheckoutLink()  | 
                                |
| 21 |     { | 
                                |
| @@ 31-38 (lines=8) @@ | ||
| 28 | /**  | 
                                |
| 29 | * MoipTest creating a billet payment.  | 
                                |
| 30 | */  | 
                                |
| 31 | public function testBillet()  | 
                                |
| 32 |     { | 
                                |
| 33 | $this->mockHttpSession($this->body_order);  | 
                                |
| 34 | $order = $this->createOrder()->create();  | 
                                |
| 35 | $this->mockHttpSession($this->body_billet_pay);  | 
                                |
| 36 |         $payment = $order->payments()->setBoleto(new \DateTime('today +1day'), 'http://dev.moip.com.br/images/logo-header-moip.png')->execute(); | 
                                |
| 37 | $this->assertNotEmpty($payment->getFundingInstrument()->boleto);  | 
                                |
| 38 | }  | 
                                |
| 39 | ||
| 40 | public function testCreditCardPCIStore()  | 
                                |
| 41 |     { | 
                                |
| @@ 84-91 (lines=8) @@ | ||
| 81 | /**  | 
                                |
| 82 | * MoipTest creating a billet multipayment.  | 
                                |
| 83 | */  | 
                                |
| 84 | public function testMultipaymentBillet()  | 
                                |
| 85 |     { | 
                                |
| 86 | $this->mockHttpSession($this->body_multiorder);  | 
                                |
| 87 | $order = $this->createMultiorder()->create();  | 
                                |
| 88 | $this->mockHttpSession($this->body_billet_multipay);  | 
                                |
| 89 |         $payment = $order->multipayments()->setBoleto(new \DateTime('today +1day'), 'http://dev.moip.com.br/images/logo-header-moip.png')->execute(); | 
                                |
| 90 | $this->assertNotEmpty($payment->getFundingInstrument()->boleto);  | 
                                |
| 91 | }  | 
                                |
| 92 | ||
| 93 | public function testCapturePreAuthorizedPayment()  | 
                                |
| 94 |     { | 
                                |