diff options
Diffstat (limited to 'tests/phpunit')
-rw-r--r-- | tests/phpunit/ResourceLoaderTestCase.php | 2 | ||||
-rw-r--r-- | tests/phpunit/includes/ResourceLoader/ModuleTest.php | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tests/phpunit/ResourceLoaderTestCase.php b/tests/phpunit/ResourceLoaderTestCase.php index e12d0b2cc3f2..6f3be0ea83c2 100644 --- a/tests/phpunit/ResourceLoaderTestCase.php +++ b/tests/phpunit/ResourceLoaderTestCase.php @@ -155,7 +155,7 @@ class ResourceLoaderTestModule extends Module { // This enables the validation check that replaces invalid // scripts with a warning message. // Based on $wgResourceLoaderValidateJS - return $this->validateScriptFile( 'input', $this->script ); + return $this->validateScriptFile( 'input.js', $this->script ); } else { return $this->script; } diff --git a/tests/phpunit/includes/ResourceLoader/ModuleTest.php b/tests/phpunit/includes/ResourceLoader/ModuleTest.php index 951e4f916bd0..b9d7bddf2e0a 100644 --- a/tests/phpunit/includes/ResourceLoader/ModuleTest.php +++ b/tests/phpunit/includes/ResourceLoader/ModuleTest.php @@ -156,17 +156,17 @@ class ModuleTest extends ResourceLoaderTestCase { yield 'valid ES2017 async-await' => [ "var foo = async function(x) { return await x.fetch(); }", - 'Parse error: Unexpected: function on line 1' + 'Parse error: Unexpected: function on line 1 in input.js' ]; yield 'valid ES2018 spread in object literal' => [ "var x = {b: 2, c: 3}; var y = {a: 1, ...x};", - 'Parse error: Unexpected: ... on line 1' + 'Parse error: Unexpected: ... on line 1 in input.js' ]; yield 'SyntaxError' => [ "var a = 'this is';\n {\ninvalid", - 'Parse error: Unclosed { on line 3' + 'Parse error: Unclosed { on line 3 in input.js' ]; // If an implementation matches inputs using a regex with runaway backtracking, |