Update command unit tests to use helper functions

This commit is contained in:
Dane Everitt 2017-09-22 00:30:09 -05:00
parent 8df5d5beaf
commit 6e5b0b8027
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
13 changed files with 615 additions and 100 deletions

View file

@ -83,6 +83,7 @@ class ProcessRunnableCommandTest extends CommandTestCase
$this->processScheduleService->shouldReceive('handle')->with($schedule)->once()->andReturnNull();
$display = $this->runCommand($this->command);
$this->assertNotEmpty($display);
$this->assertContains(trans('command/messages.schedule.output_line', [
'schedule' => $schedule->name,
@ -103,6 +104,7 @@ class ProcessRunnableCommandTest extends CommandTestCase
$this->repository->shouldReceive('getSchedulesToProcess')->with('00:00:00')->once()->andReturn(collect([$schedule]));
$display = $this->runCommand($this->command);
$this->assertNotEmpty($display);
$this->assertNotContains(trans('command/messages.schedule.output_line', [
'schedule' => $schedule->name,
@ -122,6 +124,7 @@ class ProcessRunnableCommandTest extends CommandTestCase
$this->repository->shouldReceive('getSchedulesToProcess')->with('00:00:00')->once()->andReturn(collect([$schedule]));
$display = $this->runCommand($this->command);
$this->assertNotEmpty($display);
$this->assertNotContains(trans('command/messages.schedule.output_line', [
'schedule' => $schedule->name,