From: Timo Tijhof Date: Mon, 15 Apr 2019 19:21:00 +0000 (+0100) Subject: resourceloader: Use 'fallback' as default for ResourceLoaderTestCase X-Git-Tag: 1.34.0-rc.0~1960^2 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/pie.php?a=commitdiff_plain;h=b54a1e709e5270c5d7f2ef020306db41868becfb;p=lhc%2Fweb%2Fwiklou.git resourceloader: Use 'fallback' as default for ResourceLoaderTestCase Follows-up fa05976f5f. This broke the Travis CI tests because the Vector skin is not installed there (unlike in Wikimedia CI). Make the test no longer reliant on that detail. * Fix ResourceLoaderTestCase to use a default that actually works in plain core (previously 'vector' would be rejected as being an unknown skin, but then be re-normalised back to 'vector' thanks to wgDefaultSkin. This was fixed in fa05976f5f, and the unknown skin now produces 'fallback' which is better. * Update ResourceLoaderOOUIImageModuleTest to match this new default and also fix the test message while at it to mention 'skin', not 'image'. Change-Id: I5fb69a6a38a42b1a5f325c0134e01ad880f65087 --- diff --git a/tests/phpunit/ResourceLoaderTestCase.php b/tests/phpunit/ResourceLoaderTestCase.php index c7fb48b6f3..57f56f4400 100644 --- a/tests/phpunit/ResourceLoaderTestCase.php +++ b/tests/phpunit/ResourceLoaderTestCase.php @@ -29,7 +29,7 @@ abstract class ResourceLoaderTestCase extends MediaWikiTestCase { 'debug' => 'true', 'lang' => 'en', 'dir' => 'ltr', - 'skin' => 'vector', + 'skin' => 'fallback', 'modules' => 'startup', 'only' => 'scripts', 'safemode' => null, diff --git a/tests/phpunit/includes/resourceloader/ResourceLoaderOOUIImageModuleTest.php b/tests/phpunit/includes/resourceloader/ResourceLoaderOOUIImageModuleTest.php index ea220f1148..30e9f300c1 100644 --- a/tests/phpunit/includes/resourceloader/ResourceLoaderOOUIImageModuleTest.php +++ b/tests/phpunit/includes/resourceloader/ResourceLoaderOOUIImageModuleTest.php @@ -56,9 +56,9 @@ class ResourceLoaderOOUIImageModuleTest extends ResourceLoaderTestCase { 'Generated styles use the default image (embed)' ); $this->assertRegExp( - '/vector/', + '/fallback/', $styles['all'], - 'Generated styles use the default image (link)' + 'Generated styles use the default skin (link)' ); }