public function testGetMyAccountBalance() { $client = new Client('designman', 'batman'); $balance = $client->getMyAccountBalance(); $this->assertEquals('1600 USD', $balance); $this->setExpectedException('AccountException'); $client = new Client('hacker', 'batman'); $client->getMyAccountBalance(); }
<?php require 'bankaccount.php'; $client = new Client('designman', 'batman'); $balance = $client->getMyAccountBalance(); echo $balance;