public function testGetCurrencies() { $currencies = Utilities::getCurrencies(); $this->assertArrayHasKey('GBP', $currencies); $this->assertArrayHasKey('AUD', $currencies); $this->assertArrayHasKey('USD', $currencies); }
/** * Set currency in which you wish to trade * * @param string $currency Currency */ public function setCurrency($currency) { $currencies = Utilities::getCurrencies(); if (isset($currencies[$currency])) { $this->currency = $currency; } else { throw new InvalidArgumentException("Invalid currency code, ISO 4217 Expected" . $currency . " given"); } }