Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
test262-runner misbehaves when test file YAML has a trailing space
https://bugs.webkit.org/show_bug.cgi?id=193053

Reviewed by Yusuke Suzuki.

JSTests:

* test262/expectations.yaml:
Mark two dozen tests as passing (and correct the output of another).

Tools:

* Scripts/test262/Runner.pm:
(parseData):
Accept trailing space when parsing a test file's YAML block.


Canonical link: https://commits.webkit.org/207633@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@239605 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
rkirsling committed Jan 4, 2019
1 parent 5797091 commit 519dbda
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 42 deletions.
10 changes: 10 additions & 0 deletions JSTests/ChangeLog
@@ -1,3 +1,13 @@
2019-01-03 Ross Kirsling <ross.kirsling@sony.com>

test262-runner misbehaves when test file YAML has a trailing space
https://bugs.webkit.org/show_bug.cgi?id=193053

Reviewed by Yusuke Suzuki.

* test262/expectations.yaml:
Mark two dozen tests as passing (and correct the output of another).

2018-12-30 Yusuke Suzuki <yusukesuzuki@slowstart.org>

Unreviewed, JSTests gardening with memoryLimited
Expand Down
42 changes: 1 addition & 41 deletions JSTests/test262/expectations.yaml
Expand Up @@ -1049,9 +1049,6 @@ test/built-ins/Object/defineProperties/15.2.3.7-5-a-16.js:
test/built-ins/Object/defineProperties/15.2.3.7-5-b-248.js:
default: 'TypeError: Property description must be an object.'
strict mode: 'TypeError: Property description must be an object.'
test/built-ins/Object/defineProperty/15.2.3.6-4-289-1.js:
default: "ReferenceError: Can't find variable: verifyEqualTo"
strict mode: "ReferenceError: Can't find variable: verifyEqualTo"
test/built-ins/Object/internals/DefineOwnProperty/consistent-value-function-arguments.js:
default: 'Test262Error: Expected SameValue(«null», «[object Arguments]») to be true'
test/built-ins/Object/internals/DefineOwnProperty/consistent-value-function-caller.js:
Expand Down Expand Up @@ -6782,18 +6779,6 @@ test/language/expressions/object/method-definition/yield-as-function-expression-
strict mode: "SyntaxError: Cannot use 'yield' as a function name in strict mode."
test/language/expressions/object/method-definition/yield-as-identifier-in-nested-function.js:
strict mode: "SyntaxError: Unexpected keyword 'yield'. Cannot use yield expression out of generator."
test/language/expressions/object/method-definition/yield-as-logical-or-expression.js:
default: "SyntaxError: Unexpected token '?'"
strict mode: "SyntaxError: Unexpected token '?'"
test/language/expressions/object/method-definition/yield-as-parameter.js:
default: "SyntaxError: Cannot use 'yield' as a parameter name in a generator function."
strict mode: "SyntaxError: Cannot use 'yield' as a parameter name in strict mode."
test/language/expressions/object/method-definition/yield-star-after-newline.js:
default: "SyntaxError: Unexpected token '*'"
strict mode: "SyntaxError: Unexpected token '*'"
test/language/expressions/object/method-definition/yield-weak-binding.js:
default: "SyntaxError: Unexpected number '3'"
strict mode: "SyntaxError: Unexpected number '3'"
test/language/expressions/object/scope-gen-meth-body-lex-distinct.js:
default: 'Test262Error: Expected a SyntaxError to be thrown but no exception was thrown at all'
test/language/expressions/object/scope-gen-meth-param-elem-var-close.js:
Expand Down Expand Up @@ -6953,9 +6938,6 @@ test/language/global-code/script-decl-func-err-non-extensible.js:
test/language/global-code/script-decl-var-err.js:
default: 'Test262Error: Expected a TypeError to be thrown but no exception was thrown at all'
strict mode: 'Test262Error: Expected a TypeError to be thrown but no exception was thrown at all'
test/language/identifiers/val-yield-strict.js:
default: 'Test262: This statement should not be evaluated.'
strict mode: "SyntaxError: Cannot use 'yield' as a variable name in strict mode."
test/language/literals/numeric/numeric-separator-literal-bil-bd-nsl-bd.js:
default: 'SyntaxError: No space between binary literal and identifier'
strict mode: 'SyntaxError: No space between binary literal and identifier'
Expand Down Expand Up @@ -7158,8 +7140,7 @@ test/language/module-code/instn-resolve-order-depth.js:
test/language/module-code/instn-resolve-order-src.js:
module: "SyntaxError: 'break' is only valid inside a switch or loop statement."
test/language/module-code/instn-star-as-props-dflt-skip.js:
default: "SyntaxError: Unexpected token '{'. import call expects exactly one argument."
strict mode: "SyntaxError: Unexpected token '{'. import call expects exactly one argument."
module: "SyntaxError: Unexpected identifier 'as'. Expected 'from' before exported module name."
test/language/module-code/instn-star-props-nrml.js:
module: "SyntaxError: Unexpected identifier 'as'. Expected 'from' before exported module name."
test/language/module-code/namespace/internals/define-own-property.js:
Expand Down Expand Up @@ -7193,24 +7174,6 @@ test/language/statements/class/class-name-ident-static.js:
test/language/statements/class/classelementname-abrupt-completion.js:
default: "SyntaxError: Unexpected token '}'. Expected an opening '(' before a method's parameter list."
strict mode: "SyntaxError: Unexpected token '}'. Expected an opening '(' before a method's parameter list."
test/language/statements/class/definition/methods-gen-yield-as-function-expression-binding-identifier.js:
default: "SyntaxError: Cannot use 'yield' as a function name in strict mode."
strict mode: "SyntaxError: Cannot use 'yield' as a function name in strict mode."
test/language/statements/class/definition/methods-gen-yield-as-identifier-in-nested-function.js:
default: "SyntaxError: Unexpected keyword 'yield'. Cannot use yield expression out of generator."
strict mode: "SyntaxError: Unexpected keyword 'yield'. Cannot use yield expression out of generator."
test/language/statements/class/definition/methods-gen-yield-as-logical-or-expression.js:
default: "SyntaxError: Unexpected token '?'"
strict mode: "SyntaxError: Unexpected token '?'"
test/language/statements/class/definition/methods-gen-yield-as-parameter.js:
default: "SyntaxError: Cannot use 'yield' as a parameter name in strict mode."
strict mode: "SyntaxError: Cannot use 'yield' as a parameter name in strict mode."
test/language/statements/class/definition/methods-gen-yield-star-after-newline.js:
default: "SyntaxError: Unexpected token '*'"
strict mode: "SyntaxError: Unexpected token '*'"
test/language/statements/class/definition/methods-gen-yield-weak-binding.js:
default: "SyntaxError: Unexpected number '3'"
strict mode: "SyntaxError: Unexpected number '3'"
test/language/statements/class/dstr-private-gen-meth-ary-init-iter-close.js:
default: "SyntaxError: Invalid character: '#'"
strict mode: "SyntaxError: Invalid character: '#'"
Expand Down Expand Up @@ -11073,9 +11036,6 @@ test/language/statements/labeled/value-yield-non-strict-escaped.js:
default: "SyntaxError: Unexpected escaped characters in keyword token: 'yi\\u0065ld'"
test/language/statements/labeled/value-yield-non-strict.js:
strict mode: "SyntaxError: Cannot use 'yield' as a label in strict mode."
test/language/statements/labeled/value-yield-strict.js:
default: 'Test262: This statement should not be evaluated.'
strict mode: "SyntaxError: Cannot use 'yield' as a label in strict mode."
test/language/statements/let/block-local-closure-set-before-initialization.js:
default: 'Test262Error: Expected a ReferenceError to be thrown but no exception was thrown at all'
test/language/statements/let/syntax/attempt-to-redeclare-let-binding-with-function-declaration.js:
Expand Down
11 changes: 11 additions & 0 deletions Tools/ChangeLog
@@ -1,3 +1,14 @@
2019-01-03 Ross Kirsling <ross.kirsling@sony.com>

test262-runner misbehaves when test file YAML has a trailing space
https://bugs.webkit.org/show_bug.cgi?id=193053

Reviewed by Yusuke Suzuki.

* Scripts/test262/Runner.pm:
(parseData):
Accept trailing space when parsing a test file's YAML block.

2019-01-03 Michael Catanzaro <mcatanzaro@igalia.com>

UserMedia test should use WKPageNavigationClient
Expand Down
2 changes: 1 addition & 1 deletion Tools/Scripts/test262/Runner.pm
Expand Up @@ -871,7 +871,7 @@ sub parseData {

my $parsed;
my $found = '';
if ($contents =~ /\/\*(---[\r\n]+[\S\s]*)[\r\n]+---\*\//m) {
if ($contents =~ /\/\*(---[\r\n]+[\S\s]*)[\r\n]+\s*---\*\//m) {
$found = $1;
};

Expand Down

0 comments on commit 519dbda

Please sign in to comment.