Exemplo n.º 1
0
 /**
  * Report Exception
  *
  * Information:
  * We can not provide better testing for Handler::report()
  * because parent::report() do not return anything.
  * Ref: Illuminate\Foundation\Exceptions\Handler
  */
 public function testReport()
 {
     $log = Mockery::mock('Illuminate\\Log\\Writer');
     $handler = new Handler($log);
     $exception = new HttpException('404', 'My test exception');
     $result = $handler->report($exception);
     $this->assertEquals(null, $result);
 }
Exemplo n.º 2
0
 /**
  * Report Exception
  *
  * Information:
  * We can not provide better testing for Handler::report()
  * because parent::report() do not return anything.
  * Ref: Illuminate\Foundation\Exceptions\Handler
  */
 public function testReportWithException()
 {
     $log = Mockery::mock('Illuminate\\Log\\Writer');
     $log->shouldReceive('error');
     $handler = new Handler($log);
     $exception = new Exception('My test exception');
     $result = $handler->report($exception);
     $this->assertEquals(null, $result);
 }