Skip to content

Commit

Permalink
Fix tests of a web response
Browse files Browse the repository at this point in the history
  • Loading branch information
Kolyunya committed Mar 23, 2017
1 parent da3bb5a commit a35eada
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions tests/framework/web/ResponseTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ public function testSetStatusCodeByException($exception, $statusCode)

public function dataProviderSetStatusCodeByException()
{
return [
$data = [
[
new Exception(),
500,
Expand All @@ -144,10 +144,6 @@ public function dataProviderSetStatusCodeByException()
new RuntimeException(),
500,
],
[
new Error(),
500,
],
[
new HttpException(500),
500,
Expand All @@ -169,5 +165,14 @@ public function dataProviderSetStatusCodeByException()
200,
],
];

if (class_exists('Error')) {
$data[] = [
new Error(),
500,
];
}

return $data;
}
}

0 comments on commit a35eada

Please sign in to comment.