1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-02 23:07:39 +02:00

[ticket/11568] Only assert string when doctype is there at all

PHPBB3-11568
This commit is contained in:
Joas Schilling
2013-05-30 14:12:08 +02:00
parent e84fb0c6ca
commit 45c91be970

View File

@@ -478,6 +478,9 @@ class phpbb_functional_test_case extends phpbb_test_case
$content = self::$client->getResponse()->getContent(); $content = self::$client->getResponse()->getContent();
// Any output before the doc type means there was an error // Any output before the doc type means there was an error
if (strpos($content, '<!DOCTYPE') !== false)
{
self::assertStringStartsWith('<!DOCTYPE', trim($content), 'Output found before DOCTYPE specification.'); self::assertStringStartsWith('<!DOCTYPE', trim($content), 'Output found before DOCTYPE specification.');
} }
} }
}