/** * @param $id * @return CustomerBankAccount */ public function getCustomerBankAccount($id) { $account = new CustomerBankAccount(); $account->fromArray($this->get(self::ENDPOINT_CUSTOMER_BANK, [], $id)); return $account; }
/** * @depends testListCustomerBankAccounts * @param CustomerBankAccount $old */ public function testGetCustomerBankAccount($old) { $new = $this->getClient()->getCustomerBankAccount($old->getId()); $newArray = $new->toArray(); $oldArray = $old->toArray(); $this->assertEquals($newArray, $oldArray); }
public function fromArray($data) { parent::fromArray($data); $this->setCreatedAt(new \DateTime($this->getCreatedAt())); }