Improve test coverage.

This commit is contained in:
James Cole
2019-08-29 17:53:25 +02:00
parent 91b6b86202
commit 19feefda2d
86 changed files with 3173 additions and 2626 deletions

View File

@@ -26,6 +26,7 @@ use FireflyIII\Repositories\PiggyBank\PiggyBankRepositoryInterface;
use Illuminate\Support\Collection;
use Log;
use Tests\TestCase;
use Amount;
/**
* Class FrontpageControllerTest
@@ -57,6 +58,8 @@ class FrontpageControllerTest extends TestCase
$repository->shouldReceive('getPiggyBanks')->andReturn(new Collection([$piggy]));
$repository->shouldReceive('getCurrentAmount')->andReturn('10');
Amount::shouldReceive('formatAnything')->atLeast()->once()->andReturn('x');
$this->be($this->user());
$response = $this->get(route('json.fp.piggy-banks'));
$response->assertStatus(200);