public function testdeductFunds_InvalidAmount() { $service = new \Box\Mod\Client\ServiceBalance(); $clientModel = new \Model_Client(); $clientModel->loadBean(new \RedBeanPHP\OODBBean()); $description = 'Charged'; $amount = "5.5adadzxc"; $extra = array('rel_id' => 1); $this->setExpectedException('\\Box_Exception', 'Funds amount is not valid'); $service->deductFunds($clientModel, $amount, $description, $extra); }