From 2147a5eba5020b9f602b232da6a1f138479f77fa Mon Sep 17 00:00:00 2001 From: Dhruv Date: Mon, 23 Jun 2014 21:23:47 +0530 Subject: [PATCH] [ticket/11528] Handle case when config file cant be written by installer PHPBB3-11528 --- tests/test_framework/phpbb_mink_test_case.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/test_framework/phpbb_mink_test_case.php b/tests/test_framework/phpbb_mink_test_case.php index 93b7beea99..89042e46c1 100644 --- a/tests/test_framework/phpbb_mink_test_case.php +++ b/tests/test_framework/phpbb_mink_test_case.php @@ -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());