diff --git a/test/language/line-terminators/7.3-1.js b/test/language/line-terminators/7.3-1.js deleted file mode 100644 index 40c575c4f4405c2289ea3479e099d0ae38912cf8..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/7.3-1.js +++ /dev/null @@ -1,15 +0,0 @@ -// Copyright (c) 2012 Ecma International. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -es5id: 7.3-1 -description: > - 7.3 - ES5 recognizes the character <LS> (\u2028) as line - terminators when parsing statements ----*/ - - var test7_3_1, prop; - eval("test7_3_1\u2028prop = 66;"); - -assert.sameValue(prop, 66, 'prop'); -assert.sameValue((typeof test7_3_1), "undefined", '(typeof test7_3_1)'); diff --git a/test/language/line-terminators/7.3-10.js b/test/language/line-terminators/7.3-10.js deleted file mode 100644 index 91ed519db9640d71f8928e9a8db361be7fff8aec..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/7.3-10.js +++ /dev/null @@ -1,14 +0,0 @@ -// Copyright (c) 2012 Ecma International. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -es5id: 7.3-10 -description: > - 7.3 - ES5 recognizes the character <PS> (\u2029) as a - NonEscapeCharacter ----*/ - - -assert.throws(SyntaxError, function() { - eval("var prop = \\u2029;"); -}); diff --git a/test/language/line-terminators/7.3-2.js b/test/language/line-terminators/7.3-2.js deleted file mode 100644 index 5373947ae018498574272d71dd601a8de24bf0b2..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/7.3-2.js +++ /dev/null @@ -1,15 +0,0 @@ -// Copyright (c) 2012 Ecma International. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -es5id: 7.3-2 -description: > - 7.3 - ES5 recognizes the character <PS> (\u2029) as line - terminators when parsing statements ----*/ - - var test7_3_2, prop; - eval("test7_3_2\u2029prop = 66;"); - -assert.sameValue(prop, 66, 'prop'); -assert.sameValue((typeof test7_3_2), "undefined", '(typeof test7_3_2)'); diff --git a/test/language/line-terminators/7.3-3.js b/test/language/line-terminators/7.3-3.js deleted file mode 100644 index 1e176b858053cb2f9869e22bfe9e8bfc6bb69aa5..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/7.3-3.js +++ /dev/null @@ -1,14 +0,0 @@ -// Copyright (c) 2012 Ecma International. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -es5id: 7.3-3 -description: > - 7.3 - ES5 recognizes the character <LS> (\u2028) as terminating - SingleLineComments ----*/ - - -assert.throws(SyntaxError, function() { - eval("//Single Line Comments\u2028 var =;"); -}); diff --git a/test/language/line-terminators/7.3-4.js b/test/language/line-terminators/7.3-4.js deleted file mode 100644 index b882828e563b1b9ebaea0d90c9189bde4fa576f1..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/7.3-4.js +++ /dev/null @@ -1,14 +0,0 @@ -// Copyright (c) 2012 Ecma International. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -es5id: 7.3-4 -description: > - 7.3 - ES5 recognizes the character <PS> (\u2029) as terminating - SingleLineComments ----*/ - - -assert.throws(SyntaxError, function() { - eval("//Single Line Comments\u2029 var =;"); -}); diff --git a/test/language/line-terminators/7.3-9.js b/test/language/line-terminators/7.3-9.js deleted file mode 100644 index 55645b1fe2bd98366a507476009756540a4898fc..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/7.3-9.js +++ /dev/null @@ -1,14 +0,0 @@ -// Copyright (c) 2012 Ecma International. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -es5id: 7.3-9 -description: > - 7.3 - ES5 recognizes the character <LS> (\u2028) as a - NonEscapeCharacter ----*/ - - -assert.throws(SyntaxError, function() { - eval("var prop = \\u2028;"); -}); diff --git a/test/language/line-terminators/S7.3_A1.1_T1.js b/test/language/line-terminators/S7.3_A1.1_T1.js deleted file mode 100644 index fab57101fc2eee449df80995851f284e70141799..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A1.1_T1.js +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: LINE FEED (U+000A) may occur between any two tokens -es5id: 7.3_A1.1_T1 -description: Insert LINE FEED (\u000A and \n) between tokens of var x=1 ----*/ - -var result; - -// CHECK#1 -eval("\u000Avar\u000Ax\u000A=\u000A1\u000A; result = x;"); -if (result !== 1) { - $ERROR('#1: eval("\\u000Avar\\u000Ax\\u000A=\\u000A1\\u000A; result = x;"); result === 1. Actual: ' + (result)); -} - -//CHECK#2 -eval("\u000A" + "var" + "\u000A" + "x" + "\u000A" + "=" + "\u000A" + "2" + "\u000A; result = x;"); -if (result !== 2) { - $ERROR('#2: eval("\\u000A" + "var" + "\\u000A" + "x" + "\\u000A" + "=" + "\\u000A" + "2" + "\\u000A; result = x;"); result === 2. Actual: ' + (result)); -} - -//CHECK#3 -eval("\nvar\nx\n=\n3\n; result = x;"); -if (result !== 3) { - $ERROR('#3: eval("\\nvar\\nx\\n=\\n3\\n; result = x;"); result === 3. Actual: ' + (result)); -} - -//CHECK#4 -eval("\n" + "var" + "\n" + "x" + "\n" + "=" + "\n" + "4" + "\n; result = x;"); -if (result !== 4) { - $ERROR('#4: eval("\\n" + "var" + "\\n" + "x" + "\\n" + "=" + "\\n" + "4" + "\\n; result = x;"); result === 4. Actual: ' + (result)); -} - -//CHECK#5 -eval("\u000A" + "var" + "\n" + "x" + "\u000A" + "=" + "\n" + "5" + "\u000A; result = x;"); -if (result !== 5) { - $ERROR('#5: eval("\\u000A" + "var" + "\\n" + "x" + "\\u000A" + "=" + "\\n" + "5" + "\\u000A; result = x;"); result === 5. Actual: ' + (result)); -} diff --git a/test/language/line-terminators/S7.3_A1.2_T1.js b/test/language/line-terminators/S7.3_A1.2_T1.js deleted file mode 100644 index 7d47f91d2a0b93bee31dea10afef1e61d3c65bfb..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A1.2_T1.js +++ /dev/null @@ -1,40 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: CARRIAGE RETURN (U+000D) may occur between any two tokens -es5id: 7.3_A1.2_T1 -description: Insert CARRIAGE RETURN (\u000D and \r) between tokens of var x=1 ----*/ - -var result; - -// CHECK#1 -eval("\u000Dvar\u000Dx\u000D=\u000D1\u000D; result = x;"); -if (result !== 1) { - $ERROR('#1: eval("\\u000Dvar\\u000Dx\\u000D=\\u000D1\\u000D"); result === 1. Actual: ' + (result)); -} - -//CHECK#2 -eval("\u000D" + "var" + "\u000D" + "x" + "\u000D" + "=" + "\u000D" + "2" + "\u000D; result = x;"); -if (result !== 2) { - $ERROR('#2: eval("\\u000D" + "var" + "\\u000D" + "x" + "\\u000D" + "=" + "\\u000D" + "2" + "\\u000D"); result === 2. Actual: ' + (result)); -} - -//CHECK#3 -eval("\rvar\rx\r=\r3\r; result = x;"); -if (result !== 3) { - $ERROR('#3: eval("\\rvar\\rx\\r=\\r3\\r"); result === 3. Actual: ' + (result)); -} - -//CHECK#4 -eval("\r" + "var" + "\r" + "x" + "\r" + "=" + "\r" + "4" + "\r; result = x;"); -if (result !== 4) { - $ERROR('#4: eval("\\r" + "var" + "\\r" + "x" + "\\r" + "=" + "\\r" + "4" + "\\r"); result === 4. Actual: ' + (result)); -} - -//CHECK#5 -eval("\u000D" + "var" + "\r" + "x" + "\u000D" + "=" + "\r" + "5" + "\u000D; result = x;"); -if (result !== 5) { - $ERROR('#5: eval("\\u000D" + "var" + "\\r" + "x" + "\\u000D" + "=" + "\\r" + "5" + "\\u000D"); result === 5. Actual: ' + (result)); -} diff --git a/test/language/line-terminators/S7.3_A1.3.js b/test/language/line-terminators/S7.3_A1.3.js deleted file mode 100644 index f8073d875702b1813fa337c0a0d65726c0a0abcf..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A1.3.js +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: LINE SEPARATOR (U+2028) may occur between any two tokens -es5id: 7.3_A1.3 -description: Insert LINE SEPARATOR (\u2028) between tokens of var x=1 ----*/ - -var result; - -// CHECK#1 -eval("\u2028var\u2028x\u2028=\u20281\u2028; result = x;"); -if (result !== 1) { - $ERROR('#1: eval("\\u2028var\\u2028x\\u2028=\\u20281\\u2028"); result === 1. Actual: ' + (result)); -} - -//CHECK#2 -eval("\u2028" + "var" + "\u2028" + "x" + "\u2028" + "=" + "\u2028" + "2" + "\u2028; result = x;"); -if (result !== 2) { - $ERROR('#2: eval("\\u2028" + "var" + "\\u2028" + "x" + "\\u2028" + "=" + "\\u2028" + "2" + "\\u2028"); result === 2. Actual: ' + (result)); -} diff --git a/test/language/line-terminators/S7.3_A1.4.js b/test/language/line-terminators/S7.3_A1.4.js deleted file mode 100644 index d137ba2dfcd8866e3304d378e4fbc530be98b059..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A1.4.js +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: PARAGRAPH SEPARATOR (U+2029) may occur between any two tokens -es5id: 7.3_A1.4 -description: Insert PARAGRAPH SEPARATOR (\u2029) between tokens of var x=1 ----*/ - -var result; - -// CHECK#1 -eval("\u2029var\u2029x\u2029=\u20291\u2029; result = x;"); -if (result !== 1) { - $ERROR('#1: eval("\\u2029var\\u2029x\\u2029=\\u20291\\u2029"); result === 1. Actual: ' + (result)); -} - -//CHECK#2 -eval("\u2029" + "var" + "\u2029" + "x" + "\u2029" + "=" + "\u2029" + "2" + "\u2029; result = x;"); -if (result !== 2) { - $ERROR('#2: eval("\\u2029" + "var" + "\\u2029" + "x" + "\\u2029" + "=" + "\\u2029" + "2" + "\\u2029"); result === 2. Actual: ' + (result)); -} diff --git a/test/language/line-terminators/S7.3_A3.1_T1.js b/test/language/line-terminators/S7.3_A3.1_T1.js deleted file mode 100644 index 45ca9558f53a9f6b3b50d9359557e0cde3fa4285..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A3.1_T1.js +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments are terminated by the LINE FEED (U+000A) character -es5id: 7.3_A3.1_T1 -description: Insert LINE FEED (\u000A) into single line comment ----*/ - -assert.throws(Test262Error, function() { - eval("// single line \u000A throw new Test262Error();"); -}); diff --git a/test/language/line-terminators/S7.3_A3.1_T2.js b/test/language/line-terminators/S7.3_A3.1_T2.js deleted file mode 100644 index 2b37ae5146394d8a090e8e4176d78a5da7822333..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A3.1_T2.js +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments can not contain LINE FEED (U+000A) inside -es5id: 7.3_A3.1_T2 -description: Insert LINE FEED (\u000A) into begin of single line comment ----*/ - -assert.throws(SyntaxError, function() { - eval("//\u000A single line comment"); -}); diff --git a/test/language/line-terminators/S7.3_A3.2_T3.js b/test/language/line-terminators/S7.3_A3.2_T3.js deleted file mode 100644 index 14c6c29bb63083308ca29840a4c94b73711973e4..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A3.2_T3.js +++ /dev/null @@ -1,17 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments can not contain CARRIAGE RETURN (U+000D) inside -es5id: 7.3_A3.2_T3 -description: Insert real CARRIAGE RETURN into single line comment -negative: - phase: parse - type: SyntaxError ----*/ - -$DONOTEVALUATE(); - -// CHECK#1 -//single -line comment diff --git a/test/language/line-terminators/S7.3_A3.3_T2.js b/test/language/line-terminators/S7.3_A3.3_T2.js deleted file mode 100644 index fd825222018038b3b26dbdc81f1cfb240d8d86fd..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A3.3_T2.js +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments can not contain LINE SEPARATOR (U+2028) inside -es5id: 7.3_A3.3_T2 -description: Insert LINE SEPARATOR (\u2028) into begin of single line comment ----*/ - -assert.throws(SyntaxError, function() { - eval("//\u2028 single line comment"); -}); diff --git a/test/language/line-terminators/S7.3_A3.4_T2.js b/test/language/line-terminators/S7.3_A3.4_T2.js deleted file mode 100644 index 953b894a02d70a09513704a4b228fdd4f7f02e45..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A3.4_T2.js +++ /dev/null @@ -1,14 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments can not contain PARAGRAPH SEPARATOR (U+2029) inside -es5id: 7.3_A3.4_T2 -description: > - Insert PARAGRAPH SEPARATOR (\u2029) into begin of single line - comment ----*/ - -assert.throws(SyntaxError, function() { - eval("//\u2029 single line comment"); -}); diff --git a/test/language/line-terminators/S7.3_A4_T1.js b/test/language/line-terminators/S7.3_A4_T1.js deleted file mode 100644 index 5f4de83a2912334e2643dfd58fe57082bace8758..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A4_T1.js +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments can contain Line Terminator at the end of line -es5id: 7.3_A4_T1 -description: Insert LINE FEED (U+000A) into the end of single line comment ----*/ - -// CHECK#1 -eval("// single line comment\u000A"); - -// CHECK#2 -var x = 0; -eval("// single line comment\u000A x = 1;"); -if (x !== 1) { - $ERROR('#1: var x = 0; eval("// single line comment\\u000A x = 1;"); x === 1. Actual: ' + (x)); -} diff --git a/test/language/line-terminators/S7.3_A4_T2.js b/test/language/line-terminators/S7.3_A4_T2.js deleted file mode 100644 index fc1d805d23d5c38f5671f396941cb24d8b4c5875..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A4_T2.js +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments can contain Line Terminator at the end of line -es5id: 7.3_A4_T2 -description: Insert CARRIAGE RETURN (U+000D) into the end of single line comment ----*/ - -// CHECK#1 -eval("// single line comment\u000D"); - -// CHECK#2 -var x = 0; -eval("// single line comment\u000D x = 1;"); -if (x !== 1) { - $ERROR('#1: var x = 0; eval("// single line comment\\u000D x = 1;"); x === 1. Actual: ' + (x)); -} diff --git a/test/language/line-terminators/S7.3_A4_T3.js b/test/language/line-terminators/S7.3_A4_T3.js deleted file mode 100644 index 57b182938c9a20fba6e15057dd9d1695e7fded3e..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A4_T3.js +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments can contain Line Terminator at the end of line -es5id: 7.3_A4_T3 -description: Insert LINE SEPARATOR (U+2028) into the end of single line comment ----*/ - -// CHECK#1 -eval("// single line comment\u2028"); - -// CHECK#2 -var x = 0; -eval("// single line comment\u2028 x = 1;"); -if (x !== 1) { - $ERROR('#1: var x = 0; eval("// single line comment\\u2028 x = 1;"); x === 1. Actual: ' + (x)); -} diff --git a/test/language/line-terminators/S7.3_A4_T4.js b/test/language/line-terminators/S7.3_A4_T4.js deleted file mode 100644 index 9ebd1a42923f434d37bc822b06dcbc331cb57c7d..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A4_T4.js +++ /dev/null @@ -1,20 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Single line comments can contain Line Terminator at the end of line -es5id: 7.3_A4_T4 -description: > - Insert PARAGRAPH SEPARATOR (U+2029) into the end of single line - comment ----*/ - -// CHECK#1 -eval("// single line comment\u2029"); - -// CHECK#2 -var x = 0; -eval("// single line comment\u2029 x = 1;"); -if (x !== 1) { - $ERROR('#1: var x = 0; eval("// single line comment\\u2029 x = 1;"); x === 1. Actual: ' + (x)); -} diff --git a/test/language/line-terminators/S7.3_A5.1_T1.js b/test/language/line-terminators/S7.3_A5.1_T1.js deleted file mode 100644 index 95cfa678a2477a2a68a40b57087fc6e21cff6573..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A5.1_T1.js +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Multi line comment can contain LINE FEED (U+000A) -es5id: 7.3_A5.1_T1 -description: Insert LINE FEED (U+000A) into multi line comment ----*/ - -// CHECK#1 -eval("/*\u000A multi line \u000A comment \u000A*/"); - -//CHECK#2 -var x = 0; -eval("/*\u000A multi line \u000A comment \u000A x = 1;*/"); -if (x !== 0) { - $ERROR('#1: var x = 0; eval("/*\\u000A multi line \\u000A comment \\u000A x = 1;*/"); x === 0. Actual: ' + (x)); -} diff --git a/test/language/line-terminators/S7.3_A5.1_T2.js b/test/language/line-terminators/S7.3_A5.1_T2.js deleted file mode 100644 index 168faa99a3e99cec930a90c581ea2437916c8322..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A5.1_T2.js +++ /dev/null @@ -1,20 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Multi line comment can contain LINE FEED (U+000A) -es5id: 7.3_A5.1_T2 -description: Insert real LINE FEED into multi line comment ----*/ - -/*CHECK#1*/ -var x = 0; -/* -multi -line -comment -x = 1; -*/ -if (x !== 0) { - $ERROR('#1: var x = 0; /*\\nmulti\\nline\\ncomment\\nx = 1;\\n*/ x === 0. Actual: ' + (x)); -} diff --git a/test/language/line-terminators/S7.3_A5.2_T1.js b/test/language/line-terminators/S7.3_A5.2_T1.js deleted file mode 100644 index cb92ec1ccff6ad66cbc5ee8106ebfa3de0d083e0..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A5.2_T1.js +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Multi line comment can contain CARRIAGE RETURN (U+000D) -es5id: 7.3_A5.2_T1 -description: Insert CARRIAGE RETURN (U+000D) into multi line comment ----*/ - -// CHECK#1 -eval("/*\u000D multi line \u000D comment \u000D*/"); - -//CHECK#2 -var x = 0; -eval("/*\u000D multi line \u000D comment \u000D x = 1;*/"); -if (x !== 0) { - $ERROR('#1: var x = 0; eval("/*\\u000D multi line \\u000D comment \\u000D x = 1;*/"); x === 0. Actual: ' + (x)); -} diff --git a/test/language/line-terminators/S7.3_A5.3.js b/test/language/line-terminators/S7.3_A5.3.js deleted file mode 100644 index 48abd6b12c3ef2082d5e98d9d6bfcf35790a3883..0000000000000000000000000000000000000000 --- a/test/language/line-terminators/S7.3_A5.3.js +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: Multi line comment can contain LINE SEPARATOR (U+2028) -es5id: 7.3_A5.3 -description: Insert LINE SEPARATOR (U+2028) into multi line comment ----*/ - -// CHECK#1 -eval("/*\u2028 multi line \u2028 comment \u2028*/"); - -//CHECK#2 -var x = 0; -eval("/*\u2028 multi line \u2028 comment \u2028 x = 1;*/"); -if (x !== 0) { - $ERROR('#1: var x = 0; eval("/*\\u2028 multi line \\u2028 comment \\u2028 x = 1;*/"); x === 0. Actual: ' + (x)); -} diff --git a/test/language/line-terminators/S7.3_A1.2_T2.js b/test/language/line-terminators/between-tokens-cr.js similarity index 90% rename from test/language/line-terminators/S7.3_A1.2_T2.js rename to test/language/line-terminators/between-tokens-cr.js index 4cdb7d07c2f3fd7e85ca45e0fce8fa1e2d6e22b1..553f75d4ab4e60123d3a52fe0686e08ca6bcccf2 100644 --- a/test/language/line-terminators/S7.3_A1.2_T2.js +++ b/test/language/line-terminators/between-tokens-cr.js @@ -3,15 +3,13 @@ /*--- info: CARRIAGE RETURN (U+000D) may occur between any two tokens +esid: sec-line-terminators es5id: 7.3_A1.2_T2 description: Insert real CARRIAGE RETURN between tokens of var x=1 ---*/ -//CHECK#1 -var -x -= -1; +var x = 1; + if (x !== 1) { $ERROR('#1: var\\nx\\n=\\n1\\n; x === 1. Actual: ' + (x)); } diff --git a/test/language/line-terminators/S7.3_A1.1_T2.js b/test/language/line-terminators/between-tokens-lf.js similarity index 77% rename from test/language/line-terminators/S7.3_A1.1_T2.js rename to test/language/line-terminators/between-tokens-lf.js index e097f41fcc4d6d7c9235633ce9036567036ebaea..e3081d0f761245cf6beb75638b99cb2bdb8889d5 100644 --- a/test/language/line-terminators/S7.3_A1.1_T2.js +++ b/test/language/line-terminators/between-tokens-lf.js @@ -3,15 +3,14 @@ /*--- info: LINE FEED (U+000A) may occur between any two tokens +esid: sec-line-terminators es5id: 7.3_A1.1_T2 description: Insert real LINE FEED between tokens of var x=1 ---*/ -//CHECK#1 var x = 1; -if (x !== 1) { - $ERROR('#1: var\\nx\\n=\\n1\\n; x === 1. Actual: ' + (x)); -} + +assert.sameValue(x, 1); diff --git a/test/language/line-terminators/between-tokens-ls.js b/test/language/line-terminators/between-tokens-ls.js new file mode 100644 index 0000000000000000000000000000000000000000..1d338eb1ba3500305a740048fa10c425654a92e9 --- /dev/null +++ b/test/language/line-terminators/between-tokens-ls.js @@ -0,0 +1,13 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: LINE SEPARATOR (U+2028) may occur between any two tokens +esid: sec-line-terminators +es5id: 7.3_A1.3 +description: Insert LINE SEPARATOR (\u2028) between tokens of var x=1 +---*/ + +var
x
=
1
; + +assert.sameValue(x, 1); diff --git a/test/language/line-terminators/between-tokens-ps.js b/test/language/line-terminators/between-tokens-ps.js new file mode 100644 index 0000000000000000000000000000000000000000..0451419cedc32e37abd56c378093fb3f6b2c7c5d --- /dev/null +++ b/test/language/line-terminators/between-tokens-ps.js @@ -0,0 +1,13 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: PARAGRAPH SEPARATOR (U+2029) may occur between any two tokens +esid: sec-line-terminators +es5id: 7.3_A1.4 +description: Insert PARAGRAPH SEPARATOR (\u2029) between tokens of var x=1 +---*/ + +var
x
=
1
; + +assert.sameValue(x, 1); diff --git a/test/language/line-terminators/S7.3_A5.2_T2.js b/test/language/line-terminators/comment-multi-cr.js similarity index 88% rename from test/language/line-terminators/S7.3_A5.2_T2.js rename to test/language/line-terminators/comment-multi-cr.js index 47fe256c25d795622ed30847c2fbfabde1213062..98d42edca0c0dfc985b4f65ab808586114d66072 100644 --- a/test/language/line-terminators/S7.3_A5.2_T2.js +++ b/test/language/line-terminators/comment-multi-cr.js @@ -3,17 +3,14 @@ /*--- info: Multi line comment can contain CARRIAGE RETURN (U+000D) +esid: sec-line-terminators es5id: 7.3_A5.2_T2 description: Insert real CARRIAGE RETURN into multi line comment ---*/ -/*CHECK#1*/ var x = 0; /* -multi -line -comment -x = 1; +multi line comment x = 1; */ if (x !== 0) { $ERROR('#1: var x = 0; /*\\rmulti\\rline\\rcomment\\rx = 1;\\r*/ x === 0. Actual: ' + (x)); diff --git a/test/language/line-terminators/comment-multi-lf.js b/test/language/line-terminators/comment-multi-lf.js new file mode 100644 index 0000000000000000000000000000000000000000..99a36a9aac30717cba0ed1b6ad686b454cc40029 --- /dev/null +++ b/test/language/line-terminators/comment-multi-lf.js @@ -0,0 +1,30 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: Multi line comment can contain LINE FEED (U+000A) +esid: sec-line-terminators +es5id: 7.3_A5.1_T2 +description: Insert real LINE FEED into multi line comment +negative: + phase: runtime + type: Test262Error +---*/ + +// Because this test concerns the interpretation of non-executable character +// sequences within ECMAScript source code, special care must be taken to +// ensure that executable code is evaluated as expected. +// +// Express the intended behavior by intentionally throwing an error; this +// guarantees that test runners will only consider the test "passing" if +// executable sequences are correctly interpreted as such. + +var x = 0; + +/* +x = 1; +*/ + +if (x === 0) { + throw new Test262Error(); +} diff --git a/test/language/line-terminators/comment-multi-ls.js b/test/language/line-terminators/comment-multi-ls.js new file mode 100644 index 0000000000000000000000000000000000000000..64d9873a07d6d562a4b3b3754b82bde90949aa73 --- /dev/null +++ b/test/language/line-terminators/comment-multi-ls.js @@ -0,0 +1,28 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: Multi line comment can contain LINE SEPARATOR (U+2028) +esid: sec-line-terminators +es5id: 7.3_A5.3 +description: Insert LINE SEPARATOR (U+2028) into multi line comment +negative: + phase: runtime + type: Test262Error +---*/ + +// Because this test concerns the interpretation of non-executable character +// sequences within ECMAScript source code, special care must be taken to +// ensure that executable code is evaluated as expected. +// +// Express the intended behavior by intentionally throwing an error; this +// guarantees that test runners will only consider the test "passing" if +// executable sequences are correctly interpreted as such. + +var x = 0; + +/*
x = 1;
*/ + +if (x === 0) { + throw new Test262Error(); +} diff --git a/test/language/line-terminators/comment-multi-ps.js b/test/language/line-terminators/comment-multi-ps.js new file mode 100644 index 0000000000000000000000000000000000000000..3f984ec6f414603f7f71171fe4afb5d0e4c26248 --- /dev/null +++ b/test/language/line-terminators/comment-multi-ps.js @@ -0,0 +1,28 @@ +// Copyright 2019 Mike Pennisi. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: Multi line comment can contain PARAGRAPH SEPARATOR (U+2029) +esid: sec-line-terminators +es5id: 7.3_A5.1_T2 +description: Insert real PARAGRAPH SEPARATOR into multi line comment +negative: + phase: runtime + type: Test262Error +---*/ + +// Because this test concerns the interpretation of non-executable character +// sequences within ECMAScript source code, special care must be taken to +// ensure that executable code is evaluated as expected. +// +// Express the intended behavior by intentionally throwing an error; this +// guarantees that test runners will only consider the test "passing" if +// executable sequences are correctly interpreted as such. + +var x = 0; + +/*
x = 1;
*/ + +if (x === 0) { + throw new Test262Error(); +} diff --git a/test/language/line-terminators/comment-single-cr.js b/test/language/line-terminators/comment-single-cr.js new file mode 100644 index 0000000000000000000000000000000000000000..932ab27b4b74be38cc1db5b3c5e68aa92ddaa347 --- /dev/null +++ b/test/language/line-terminators/comment-single-cr.js @@ -0,0 +1,22 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: Single line comments can contain Line Terminator at the end of line +esid: sec-line-terminators +es5id: 7.3_A4_T2 +description: Insert CARRIAGE RETURN (U+000D) into the end of single line comment +negative: + phase: runtime + type: Test262Error +---*/ + +// Because this test concerns the interpretation of non-executable character +// sequences within ECMAScript source code, special care must be taken to +// ensure that executable code is evaluated as expected. +// +// Express the intended behavior by intentionally throwing an error; this +// guarantees that test runners will only consider the test "passing" if +// executable sequences are correctly interpreted as such. + +// single line throw new Test262Error(); diff --git a/test/language/line-terminators/comment-single-lf.js b/test/language/line-terminators/comment-single-lf.js new file mode 100644 index 0000000000000000000000000000000000000000..0467a5992087c4532268528592771228abd18c24 --- /dev/null +++ b/test/language/line-terminators/comment-single-lf.js @@ -0,0 +1,23 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: Single line comments are terminated by the LINE FEED (U+000A) character +esid: sec-line-terminators +es5id: 7.3_A3.1_T1 +description: Insert LINE FEED (\u000A) into single line comment +negative: + phase: runtime + type: Test262Error +---*/ + +// Because this test concerns the interpretation of non-executable character +// sequences within ECMAScript source code, special care must be taken to +// ensure that executable code is evaluated as expected. +// +// Express the intended behavior by intentionally throwing an error; this +// guarantees that test runners will only consider the test "passing" if +// executable sequences are correctly interpreted as such. + +// single line +throw new Test262Error(); diff --git a/test/language/line-terminators/comment-single-ls.js b/test/language/line-terminators/comment-single-ls.js new file mode 100644 index 0000000000000000000000000000000000000000..e47731a09b9c91878c3bdbeb72c9b0155e717a7d --- /dev/null +++ b/test/language/line-terminators/comment-single-ls.js @@ -0,0 +1,22 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: Single line comments can contain Line Terminator at the end of line +esid: sec-line-terminators +es5id: 7.3_A4_T3 +description: Insert LINE SEPARATOR (U+2028) into the end of single line comment +negative: + phase: runtime + type: Test262Error +---*/ + +// Because this test concerns the interpretation of non-executable character +// sequences within ECMAScript source code, special care must be taken to +// ensure that executable code is evaluated as expected. +// +// Express the intended behavior by intentionally throwing an error; this +// guarantees that test runners will only consider the test "passing" if +// executable sequences are correctly interpreted as such. + +// single line
throw new Test262Error(); diff --git a/test/language/line-terminators/comment-single-ps.js b/test/language/line-terminators/comment-single-ps.js new file mode 100644 index 0000000000000000000000000000000000000000..95e6ec02e39bd624fff15c02314cd127ee0b28e2 --- /dev/null +++ b/test/language/line-terminators/comment-single-ps.js @@ -0,0 +1,24 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: Single line comments can contain Line Terminator at the end of line +esid: sec-line-terminators +es5id: 7.3_A4_T4 +description: > + Insert PARAGRAPH SEPARATOR (U+2029) into the end of single line + comment +negative: + phase: runtime + type: Test262Error +---*/ + +// Because this test concerns the interpretation of non-executable character +// sequences within ECMAScript source code, special care must be taken to +// ensure that executable code is evaluated as expected. +// +// Express the intended behavior by intentionally throwing an error; this +// guarantees that test runners will only consider the test "passing" if +// executable sequences are correctly interpreted as such. + +// single line
throw new Test262Error(); diff --git a/test/language/line-terminators/S7.3_A3.2_T2.js b/test/language/line-terminators/invalid-comment-single-cr.js similarity index 65% rename from test/language/line-terminators/S7.3_A3.2_T2.js rename to test/language/line-terminators/invalid-comment-single-cr.js index 580e558a1b9cd1cce9efa2ac462a7554ecaa5250..09568f1a648cbf76473a4e8c973a49f7dbbaca5f 100644 --- a/test/language/line-terminators/S7.3_A3.2_T2.js +++ b/test/language/line-terminators/invalid-comment-single-cr.js @@ -4,9 +4,13 @@ /*--- info: Single line comments can not contain CARRIAGE RETURN (U+000D) inside es5id: 7.3_A3.2_T2 +esid: sec-line-terminators description: Insert CARRIAGE RETURN (\u000D) into begin of single line comment +negative: + phase: parse + type: SyntaxError ---*/ -assert.throws(SyntaxError, function() { - eval("//\u000D single line comment"); -}); +$DONOTEVALUATE(); + +// this text is not included in the single-line comment that precedes it diff --git a/test/language/line-terminators/S7.3_A3.1_T3.js b/test/language/line-terminators/invalid-comment-single-lf.js similarity index 100% rename from test/language/line-terminators/S7.3_A3.1_T3.js rename to test/language/line-terminators/invalid-comment-single-lf.js diff --git a/test/language/line-terminators/S7.3_A3.3_T1.js b/test/language/line-terminators/invalid-comment-single-ls.js similarity index 100% rename from test/language/line-terminators/S7.3_A3.3_T1.js rename to test/language/line-terminators/invalid-comment-single-ls.js diff --git a/test/language/line-terminators/S7.3_A3.4_T1.js b/test/language/line-terminators/invalid-comment-single-ps.js similarity index 100% rename from test/language/line-terminators/S7.3_A3.4_T1.js rename to test/language/line-terminators/invalid-comment-single-ps.js diff --git a/test/language/line-terminators/invalid-regexp-cr.js b/test/language/line-terminators/invalid-regexp-cr.js new file mode 100644 index 0000000000000000000000000000000000000000..449ee384ccc7bb11891dc93f1bba52e6e101ac6b --- /dev/null +++ b/test/language/line-terminators/invalid-regexp-cr.js @@ -0,0 +1,17 @@ +// Copyright 2019 Mike Pennisi. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +esid: sec-line-terminators +es5id: 7.3-7 +description: > + 7.3 - ES5 recognizes the character <CR> (\u000D) as terminating + regular expression literals +negative: + phase: parse + type: SyntaxError +---*/ + +$DONOTEVALUATE(); + +/ / diff --git a/test/language/line-terminators/invalid-regexp-lf.js b/test/language/line-terminators/invalid-regexp-lf.js new file mode 100644 index 0000000000000000000000000000000000000000..82fc50eb2d920040a0543fcdf22c610c57c4cd0b --- /dev/null +++ b/test/language/line-terminators/invalid-regexp-lf.js @@ -0,0 +1,18 @@ +// Copyright 2019 Mike Pennisi. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +esid: sec-line-terminators +es5id: 7.3-7 +description: > + 7.3 - ES5 recognizes the character <LF> (\u000A) as terminating + regular expression literals +negative: + phase: parse + type: SyntaxError +---*/ + +$DONOTEVALUATE(); + +/ +/ diff --git a/test/language/line-terminators/7.3-7.js b/test/language/line-terminators/invalid-regexp-ls.js similarity index 74% rename from test/language/line-terminators/7.3-7.js rename to test/language/line-terminators/invalid-regexp-ls.js index ceff108155299d2d033ed29c6b53f9bea12e6459..9c0bab7c5e6542ab5ab36f2218a0f0779f9efcb3 100644 --- a/test/language/line-terminators/7.3-7.js +++ b/test/language/line-terminators/invalid-regexp-ls.js @@ -2,13 +2,16 @@ // This code is governed by the BSD license found in the LICENSE file. /*--- +esid: sec-line-terminators es5id: 7.3-7 description: > 7.3 - ES5 recognizes the character <LS> (\u2028) as terminating regular expression literals +negative: + phase: parse + type: SyntaxError ---*/ - -assert.throws(SyntaxError, function() { - eval("var regExp = /[\u2028]/"); -}); +$DONOTEVALUATE(); + +/
/ diff --git a/test/language/line-terminators/7.3-8.js b/test/language/line-terminators/invalid-regexp-ps.js similarity index 74% rename from test/language/line-terminators/7.3-8.js rename to test/language/line-terminators/invalid-regexp-ps.js index 2d1160e70fa19e799ad915fd50b1690a68fec346..edf3496af26eb09ebeaf3beeed6c03e971821bdc 100644 --- a/test/language/line-terminators/7.3-8.js +++ b/test/language/line-terminators/invalid-regexp-ps.js @@ -2,13 +2,16 @@ // This code is governed by the BSD license found in the LICENSE file. /*--- +esid: sec-line-terminators es5id: 7.3-8 description: > 7.3 - ES5 recognizes the character <PS> (\u2029) as terminating regular expression literals +negative: + phase: parse + type: SyntaxError ---*/ - -assert.throws(SyntaxError, function() { - eval("var regExp = /[\u2029]/"); -}); +$DONOTEVALUATE(); + +/
/ diff --git a/test/language/line-terminators/S7.3_A2.2_T1.js b/test/language/line-terminators/invalid-string-cr.js similarity index 74% rename from test/language/line-terminators/S7.3_A2.2_T1.js rename to test/language/line-terminators/invalid-string-cr.js index cb4e39387d1fd2246c6162aa4b344eae16ea12c7..5d7c50e9cc7f950bc6bd7f75c5d918c2d7c9217a 100644 --- a/test/language/line-terminators/S7.3_A2.2_T1.js +++ b/test/language/line-terminators/invalid-string-cr.js @@ -4,9 +4,13 @@ /*--- info: CARRIAGE RETURN (U+000D) within strings is not allowed es5id: 7.3_A2.2_T1 +esid: sec-line-terminators description: Insert CARRIAGE RETURN (\u000D) into string +negative: + phase: parse + type: SyntaxError ---*/ -assert.throws(SyntaxError, function() { - eval("'\u000Dstr\u000Ding\u000D'"); -}); +$DONOTEVALUATE(); + +' ' diff --git a/test/language/line-terminators/S7.3_A2.1_T1.js b/test/language/line-terminators/invalid-string-lf.js similarity index 74% rename from test/language/line-terminators/S7.3_A2.1_T1.js rename to test/language/line-terminators/invalid-string-lf.js index 424b17027887269a6144c25fa4d4dca5f8d55b52..bd8b43310ab7950b02876f778cb6455b3a2029d6 100644 --- a/test/language/line-terminators/S7.3_A2.1_T1.js +++ b/test/language/line-terminators/invalid-string-lf.js @@ -4,9 +4,14 @@ /*--- info: LINE FEED (U+000A) within strings is not allowed es5id: 7.3_A2.1_T1 +esid: sec-line-terminators description: Insert LINE FEED (\u000A) into string +negative: + phase: parse + type: SyntaxError ---*/ -assert.throws(SyntaxError, function() { - eval("'\u000Astr\u000Aing\u000A'"); -}); +$DONOTEVALUATE(); + +' +' diff --git a/test/language/line-terminators/invalid-string-ls.js b/test/language/line-terminators/invalid-string-ls.js new file mode 100644 index 0000000000000000000000000000000000000000..07e0a7682daa75a95492d626425f594c4a1b2a8e --- /dev/null +++ b/test/language/line-terminators/invalid-string-ls.js @@ -0,0 +1,16 @@ +// Copyright 2019 Mike Pennisi. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: LINE SEPARATOR (U+2028) within strings is not allowed +es5id: 7.3_A2.2_T1 +esid: sec-line-terminators +description: Insert LINE SEPARATOR (\u2028) into string +negative: + phase: parse + type: SyntaxError +---*/ + +$DONOTEVALUATE(); + +'
' diff --git a/test/language/line-terminators/invalid-string-ps.js b/test/language/line-terminators/invalid-string-ps.js new file mode 100644 index 0000000000000000000000000000000000000000..d2e3dec8e54651364653b07f43c2be81dfa7719d --- /dev/null +++ b/test/language/line-terminators/invalid-string-ps.js @@ -0,0 +1,16 @@ +// Copyright 2019 Mike Pennisi. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +info: PARAGRAPH SEPARATOR (U+2029) within strings is not allowed +es5id: 7.3_A2.2_T1 +esid: sec-line-terminators +description: Insert PARAGRAPH SEPARATOR (\u2029) into string +negative: + phase: parse + type: SyntaxError +---*/ + +$DONOTEVALUATE(); + +'
'