From 4b291909e0e91ad4e8ed98030c1312a872ca3bd4 Mon Sep 17 00:00:00 2001 From: daniel Date: Mon, 27 Aug 2012 14:28:47 +0200 Subject: [PATCH] wfWarn() should cause phpunit tests to fail. This forces $wgDevelopmentWarnings to true for phpunit tests. Note that wfWarn uses the E_USER_NOTICE level per default, which may or may not actually cause test cases to fail, depending on the phpunit configuration. Change-Id: I36583fb063436cc8474873b468fc983d28377cbd --- tests/phpunit/phpunit.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/phpunit/phpunit.php b/tests/phpunit/phpunit.php index 61a20f1b1f..e4a90d8a16 100755 --- a/tests/phpunit/phpunit.php +++ b/tests/phpunit/phpunit.php @@ -34,6 +34,10 @@ class PHPUnitMaintClass extends Maintenance { global $wgMainCacheType, $wgMessageCacheType, $wgParserCacheType; global $wgLanguageConverterCacheType, $wgUseDatabaseMessages; global $wgLocaltimezone, $wgLocalisationCacheConf; + global $wgDevelopmentWarnings; + + // wfWarn should cause tests to fail + $wgDevelopmentWarnings = true; $wgMainCacheType = CACHE_NONE; $wgMessageCacheType = CACHE_NONE; -- 2.20.1