Skip to content

Commit 2acf213

Browse files
authored
Merge pull request #28 from Addvilz/fix-hhvm-tests
Fix HHVM tests
2 parents abdf1b1 + 0055743 commit 2acf213

File tree

2 files changed

+11
-9
lines changed

2 files changed

+11
-9
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
Symfony integration for [Sentry](https://getsentry.com/).
44

5+
[![Build Status](https://travis-ci.org/getsentry/sentry-symfony.svg?branch=master)](https://travis-ci.org/getsentry/sentry-symfony)
6+
57
## Installation
68

79
### Step 1: Download the Bundle

test/Sentry/SentryBundle/Test/EventListener/ExceptionListenerTest.php

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,7 @@ public function test_that_it_does_not_report_http_exception_if_included_in_captu
425425

426426
public function test_that_it_captures_exception()
427427
{
428-
$mockException = $this->getMock('Exception');
428+
$reportableException = new \Exception();
429429

430430
$mockEvent = $this
431431
->getMockBuilder('Symfony\Component\HttpKernel\Event\GetResponseForExceptionEvent')
@@ -436,14 +436,14 @@ public function test_that_it_captures_exception()
436436
$mockEvent
437437
->expects($this->once())
438438
->method('getException')
439-
->willReturn($mockException)
439+
->willReturn($reportableException)
440440
;
441441

442442
$this
443443
->mockSentryClient
444444
->expects($this->once())
445445
->method('captureException')
446-
->with($this->identicalTo($mockException))
446+
->with($this->identicalTo($reportableException))
447447
;
448448

449449
$this->containerBuilder->compile();
@@ -453,7 +453,7 @@ public function test_that_it_captures_exception()
453453

454454
public function test_that_it_captures_console_exception()
455455
{
456-
$mockException = $this->getMock('Exception');
456+
$reportableException = new \Exception();
457457

458458
$mockCommand = $this
459459
->getMockBuilder('Symfony\Component\Console\Command\Command')
@@ -482,7 +482,7 @@ public function test_that_it_captures_console_exception()
482482
$mockEvent
483483
->expects($this->once())
484484
->method('getException')
485-
->willReturn($mockException)
485+
->willReturn($reportableException)
486486
;
487487

488488
$mockEvent
@@ -496,7 +496,7 @@ public function test_that_it_captures_console_exception()
496496
->expects($this->once())
497497
->method('captureException')
498498
->with(
499-
$this->identicalTo($mockException),
499+
$this->identicalTo($reportableException),
500500
$this->identicalTo(array(
501501
'tags' => array(
502502
'command' => 'cmd name',
@@ -519,7 +519,7 @@ public function test_that_it_can_replace_client()
519519
->getMock()
520520
;
521521

522-
$mockException = $this->getMock('Exception');
522+
$reportableException = new \Exception();
523523

524524
$mockEvent = $this
525525
->getMockBuilder('Symfony\Component\HttpKernel\Event\GetResponseForExceptionEvent')
@@ -530,7 +530,7 @@ public function test_that_it_can_replace_client()
530530
$mockEvent
531531
->expects($this->once())
532532
->method('getException')
533-
->willReturn($mockException)
533+
->willReturn($reportableException)
534534
;
535535

536536
$this
@@ -543,7 +543,7 @@ public function test_that_it_can_replace_client()
543543
$replacementClient
544544
->expects($this->once())
545545
->method('captureException')
546-
->with($this->identicalTo($mockException))
546+
->with($this->identicalTo($reportableException))
547547
;
548548

549549
$this->containerBuilder->compile();

0 commit comments

Comments
 (0)