Improve test coverage and fix test code.

This commit is contained in:
James Cole
2018-08-23 18:33:39 +02:00
parent 3f493aceb2
commit d4096103cb
21 changed files with 1378 additions and 21 deletions

View File

@@ -154,7 +154,7 @@ class AvailableBudgetController extends Controller
$data = $request->getAll();
$currency = $this->currencyRepository->findNull($data['currency_id']);
if (null === $currency) {
$this->currencyRepository->findByCodeNull($data['currency_code']);
$currency = $this->currencyRepository->findByCodeNull($data['currency_code']);
}
if (null === $currency) {
throw new FireflyException('Could not find the indicated currency.');
@@ -169,6 +169,8 @@ class AvailableBudgetController extends Controller
return response()->json($manager->createData($resource)->toArray())->header('Content-Type', 'application/vnd.api+json');
}
/**
* Update the specified resource in storage.
*