From 7aa4d8fce2e61776d5f2dbf67386a589bcd7d634 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Thu, 7 Nov 2013 12:56:10 +0100 Subject: [ticket/11927] Correctly add new files on update Currently we ignore language and style files when the directory where they go to do not exist. However in 3.1 we introduce some new sub directories: * language/en/email/short/ * styles/prosilver/theme/en/ So we need to change our check to look whether the language or style exist, rather then the parent directory. PHPBB3-11927 --- .../ignore_new_file_on_update_test.php | 39 ++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 tests/functions_install/ignore_new_file_on_update_test.php (limited to 'tests') diff --git a/tests/functions_install/ignore_new_file_on_update_test.php b/tests/functions_install/ignore_new_file_on_update_test.php new file mode 100644 index 0000000000..0c05cc6907 --- /dev/null +++ b/tests/functions_install/ignore_new_file_on_update_test.php @@ -0,0 +1,39 @@ +assertEquals($expected, ignore_new_file_on_update($phpbb_root_path, $file)); + } +} -- cgit v1.2.1 From 95348c8f6d64302d2d525f2ba1a9408f1510144b Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Thu, 7 Nov 2013 13:49:55 +0100 Subject: [ticket/11927] Prefix function with phpbb_ PHPBB3-11927 --- tests/functions_install/ignore_new_file_on_update_test.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/functions_install/ignore_new_file_on_update_test.php b/tests/functions_install/ignore_new_file_on_update_test.php index 0c05cc6907..ae1dde96f7 100644 --- a/tests/functions_install/ignore_new_file_on_update_test.php +++ b/tests/functions_install/ignore_new_file_on_update_test.php @@ -34,6 +34,6 @@ class phpbb_functions_install_ignore_new_file_on_update_test extends phpbb_test_ public function test_ignore_new_file_on_update($file, $expected) { global $phpbb_root_path; - $this->assertEquals($expected, ignore_new_file_on_update($phpbb_root_path, $file)); + $this->assertEquals($expected, phpbb_ignore_new_file_on_update($phpbb_root_path, $file)); } } -- cgit v1.2.1