diff options
| author | Marc Alexander <admin@m-a-styles.de> | 2012-12-24 14:33:05 +0100 |
|---|---|---|
| committer | Marc Alexander <admin@m-a-styles.de> | 2012-12-24 14:33:05 +0100 |
| commit | 46b3c3ecc43721e53c9711a196e91c300e03a1c8 (patch) | |
| tree | c936edfeb531760c3667a41c40799dd6bb61bb80 /tests/test_framework/phpbb_functional_test_case.php | |
| parent | e444f5bf2a8b30aefb3700ce358d2a6be66c8cb5 (diff) | |
| parent | 21b9ac6c880cbee7c8bda263871b24414671672a (diff) | |
| download | forums-46b3c3ecc43721e53c9711a196e91c300e03a1c8.tar forums-46b3c3ecc43721e53c9711a196e91c300e03a1c8.tar.gz forums-46b3c3ecc43721e53c9711a196e91c300e03a1c8.tar.bz2 forums-46b3c3ecc43721e53c9711a196e91c300e03a1c8.tar.xz forums-46b3c3ecc43721e53c9711a196e91c300e03a1c8.zip | |
Merge branch 'develop' of https://github.com/phpbb/phpbb3 into develop
Diffstat (limited to 'tests/test_framework/phpbb_functional_test_case.php')
| -rw-r--r-- | tests/test_framework/phpbb_functional_test_case.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/test_framework/phpbb_functional_test_case.php b/tests/test_framework/phpbb_functional_test_case.php index 67a5050892..a051410d7b 100644 --- a/tests/test_framework/phpbb_functional_test_case.php +++ b/tests/test_framework/phpbb_functional_test_case.php @@ -424,4 +424,20 @@ class phpbb_functional_test_case extends phpbb_test_case $content = $this->client->getResponse()->getContent(); $this->assertNotContains('Fatal error:', $content); } + + public function assert_filter($crawler, $expr, $msg = null) + { + $nodes = $crawler->filter($expr); + if ($msg) + { + $msg .= "\n"; + } + else + { + $msg = ''; + } + $msg .= "`$expr` not found in DOM."; + $this->assertGreaterThan(0, count($nodes), $msg); + return $nodes; + } } |
