Merge "OutputPageTest should be independent of $wgResourceLoaderDebug setting"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Tue, 25 Sep 2018 19:36:07 +0000 (19:36 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Tue, 25 Sep 2018 19:36:07 +0000 (19:36 +0000)
tests/phpunit/includes/OutputPageTest.php

index e7b7c76..7fa88fc 100644 (file)
@@ -12,6 +12,16 @@ class OutputPageTest extends MediaWikiTestCase {
        const SCREEN_MEDIA_QUERY = 'screen and (min-width: 982px)';
        const SCREEN_ONLY_MEDIA_QUERY = 'only screen and (min-width: 982px)';
 
+       // Ensure that we don't affect the global ResourceLoader state.
+       protected function setUp() {
+               parent::setUp();
+               ResourceLoader::clearCache();
+       }
+       protected function tearDown() {
+               parent::tearDown();
+               ResourceLoader::clearCache();
+       }
+
        /**
         * @dataProvider provideRedirect
         *