Code Duplication    Length = 10-12 lines in 2 locations

tests/Resource/PaymentTest.php 2 locations

@@ 40-49 (lines=10) @@
37
        $this->assertNotEmpty($payment->getFundingInstrument()->boleto);
38
    }
39
40
    public function testCreditCardPCIStore()
41
    {
42
        $this->mockHttpSession($this->body_order);
43
        $order = $this->createOrder()->create();
44
        $cc = '5555666677778884';
45
        $this->mockHttpSession($this->body_cc_pay_pci_store);
46
        $payment = $order->payments()->setCreditCard(5, 2018, $cc, 123, $this->createCustomer(), false)->execute();
47
        $this->assertFalse($payment->getFundingInstrument()->creditCard->store);
48
        $this->assertNotEmpty($payment->getId());
49
    }
50
51
    public function testShouldCreateEscrowPaymentWithCreditCard()
52
    {
@@ 51-62 (lines=12) @@
48
        $this->assertNotEmpty($payment->getId());
49
    }
50
51
    public function testShouldCreateEscrowPaymentWithCreditCard()
52
    {
53
        $this->mockHttpSession($this->body_order);
54
        $order = $this->createOrder()->create();
55
        $cc = '5555666677778884';
56
        $this->mockHttpSession($this->body_cc_pay_pci_escrow);
57
        $payment = $order->payments()
58
            ->setCreditCard(5, 2018, $cc, 123, $this->createCustomer(), false)
59
            ->setEscrow('teste de descricao')
60
            ->execute();
61
        $this->assertEquals('teste de descricao', $payment->getEscrow()->description);
62
    }
63
}
64