1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-05 08:17:47 +02:00

[ticket/13008] Add functionnal test

PHPBB3-13008
This commit is contained in:
Tristan Darricau
2014-08-23 13:16:41 +02:00
parent 03b9eb5dcb
commit 0386b1788a
7 changed files with 68 additions and 0 deletions

View File

@@ -26,6 +26,8 @@ class phpbb_functional_extension_controller_test extends phpbb_functional_test_c
'foo/bar/event/',
'foo/bar/language/en/',
'foo/bar/styles/prosilver/template/',
'foo/foo/config/',
'foo/foo/controller/',
);
static public function setUpBeforeClass()
@@ -64,6 +66,18 @@ class phpbb_functional_extension_controller_test extends phpbb_functional_test_c
$this->phpbb_extension_manager->purge('foo/bar');
}
/**
* Check a controller for extension foo/bar.
*/
public function test_routing_resources()
{
$this->phpbb_extension_manager->enable('foo/foo');
$crawler = self::request('GET', 'app.php/foo/foo', array(), false);
self::assert_response_status_code();
$this->assertContains("foo/foo controller handle() method", $crawler->filter('body')->text());
$this->phpbb_extension_manager->purge('foo/foo');
}
/**
* Check the output of a controller using the template system
*/