diff options
Diffstat (limited to 'tests/functional/extension_controller_test.php')
-rw-r--r-- | tests/functional/extension_controller_test.php | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/tests/functional/extension_controller_test.php b/tests/functional/extension_controller_test.php index f28b321942..7f1decd5b5 100644 --- a/tests/functional/extension_controller_test.php +++ b/tests/functional/extension_controller_test.php @@ -115,8 +115,9 @@ class phpbb_functional_extension_controller_test extends phpbb_functional_test_c public function test_missing_argument() { $this->phpbb_extension_manager->enable('foo/bar'); - $crawler = $this->request('GET', 'app.php?controller=foo/baz'); - $this->assertEquals(500, $this->client->getResponse()->getStatus()); + $crawler = $this->request('GET', 'app.php?controller=foo/baz', false); + $this->request('GET', 'app.php?controller=foo/baz', false); + $this->assert_response_success(500); $this->assertContains('Missing value for argument #1: test in class phpbb_ext_foo_bar_controller:baz', $crawler->filter('body')->text()); $this->phpbb_extension_manager->purge('foo/bar'); } @@ -128,7 +129,7 @@ class phpbb_functional_extension_controller_test extends phpbb_functional_test_c { $this->phpbb_extension_manager->enable('foo/bar'); $crawler = $this->request('GET', 'app.php?controller=foo/exception'); - $this->assertEquals(500, $this->client->getResponse()->getStatus()); + $this->assert_response_success(500); $this->assertContains('Exception thrown from foo/exception route', $crawler->filter('body')->text()); $this->phpbb_extension_manager->purge('foo/bar'); } @@ -145,7 +146,7 @@ class phpbb_functional_extension_controller_test extends phpbb_functional_test_c public function test_error_ext_disabled_or_404() { $crawler = $this->request('GET', 'app.php?controller=does/not/exist'); - $this->assertEquals(404, $this->client->getResponse()->getStatus()); + $this->assert_response_success(404); $this->assertContains('No route found for "GET /does/not/exist"', $crawler->filter('body')->text()); } } |