From 0552666cf58c46f14324593ea6862d47efaedf40 Mon Sep 17 00:00:00 2001 From: rxu Date: Tue, 9 May 2017 02:13:24 +0700 Subject: [PATCH] [ticket/14972] Fix test_collection_with_mask test MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In PHP 7.2, the severity of the message “Use of undefined constant” was raised from E_NOTICE to E_WARNING, so calling $array[ITEM] causes warning caught by error collector. Use undefined offset notice to get an empty message as such. PHPBB3-14972 --- tests/error_collector_test.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/error_collector_test.php b/tests/error_collector_test.php index 273284c8fc..8ed89bbe52 100644 --- a/tests/error_collector_test.php +++ b/tests/error_collector_test.php @@ -52,8 +52,8 @@ class phpbb_error_collector_test extends phpbb_test_case 1/0; $line = __LINE__; // Cause a notice - $array = array('ITEM' => 'value'); - $value = $array[ITEM]; $line2 = __LINE__; + $array = array(0 => 'value'); + $value = $array[1]; $line2 = __LINE__; $collector->uninstall();