/**
  * @depends testListPayments
  * @param Payment $old
  */
 public function testGetPayment($old)
 {
     $new = $this->getClient()->getPayment($old->getId());
     $newArray = $new->toArray();
     $oldArray = $old->toArray();
     $this->assertEquals($newArray, $oldArray);
 }
Ejemplo n.º 2
0
 /**
  * @param Payment $payment
  * @return Payment
  */
 public function createPayment(Payment $payment)
 {
     $response = $this->post(self::ENDPOINT_PAYMENTS, $payment->toArray());
     $payment->fromArray($response);
     return $payment;
 }