Some code optimisations.

This commit is contained in:
James Cole
2019-04-09 15:42:25 +02:00
parent 97726c3822
commit 80896b7181
37 changed files with 153 additions and 129 deletions

View File

@@ -65,7 +65,8 @@ class ConvertToTransferTest extends TestCase
// mock used stuff:
$accountRepos = $this->mock(AccountRepositoryInterface::class);
$accountRepos->shouldReceive('setUser')->once();
$accountRepos->shouldReceive('findByName')->withArgs([$asset->name, [AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE]])->andReturn($asset);
$accountRepos->shouldReceive('findByName')->withArgs([$asset->name, [AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE]])
->andReturn($asset);
// fire the action:
$ruleAction = new RuleAction;
@@ -100,7 +101,8 @@ class ConvertToTransferTest extends TestCase
// mock used stuff:
$accountRepos = $this->mock(AccountRepositoryInterface::class);
$accountRepos->shouldReceive('setUser')->once();
$accountRepos->shouldReceive('findByName')->withArgs([$asset->name, [AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE]])->andReturn($asset);
$accountRepos->shouldReceive('findByName')->withArgs([$asset->name, [AccountType::ASSET, AccountType::LOAN, AccountType::DEBT, AccountType::MORTGAGE]])
->andReturn($asset);
// fire the action:
$ruleAction = new RuleAction;