[ticket/11528] Handle case when config file cant be written by installer

PHPBB3-11528
This commit is contained in:
Dhruv 2014-06-23 21:23:47 +05:30
parent f0e115fdcc
commit 2147a5eba5

View file

@ -138,7 +138,6 @@ abstract class phpbb_mink_test_case extends phpbb_test_case
// install/index.php?mode=install&sub=config_file
$page = self::click_submit();
self::assertContains('The configuration file has been written', $page->findById('main')->getText());
// Installer has created a config.php file, we will overwrite it with a
// config file of our own in order to get the DEBUG constants defined
@ -149,6 +148,12 @@ abstract class phpbb_mink_test_case extends phpbb_test_case
self::markTestSkipped("Could not write $config_file file.");
}
if (strpos($page->findById('main')->getText(), 'The configuration file has been written') === false)
{
$page = self::click_submit('dldone');
}
self::assertContains('The configuration file has been written', $page->findById('main')->getText());
// install/index.php?mode=install&sub=advanced
$page = self::click_submit();
self::assertContains('The settings on this page are only necessary to set if you know that you require something different from the default.', $page->findById('main')->getText());