diff options
Diffstat (limited to 'external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators')
44 files changed, 902 insertions, 0 deletions
diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.1_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.1_T1.js new file mode 100644 index 000000000..fcc686aa3 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.1_T1.js @@ -0,0 +1,39 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A1.1_T1; + * @section: 7.3; + * @assertion: LINE FEED (U+000A) may occur between any two tokens; + * @description: Insert LINE FEED (\u000A and \n) between tokens of var x=1; +*/ + +// CHECK#1 +eval("\u000Avar\u000Ax\u000A=\u000A1\u000A"); +if (x !== 1) { + $ERROR('#1: eval("\\u000Avar\\u000Ax\\u000A=\\u000A1\\u000A"); x === 1. Actual: ' + (x)); +} + +//CHECK#2 +eval("\u000A" + "var" + "\u000A" + "x" + "\u000A" + "=" + "\u000A" + "1" + "\u000A"); +if (x !== 1) { + $ERROR('#2: eval("\\u000A" + "var" + "\\u000A" + "x" + "\\u000A" + "=" + "\\u000A" + "1" + "\\u000A"); x === 1. Actual: ' + (x)); +} + +//CHECK#3 +eval("\nvar\nx\n=\n1\n"); +if (x !== 1) { + $ERROR('#3: eval("\\nvar\\nx\\n=\\n1\\n"); x === 1. Actual: ' + (x)); +} + +//CHECK#4 +eval("\n" + "var" + "\n" + "x" + "\n" + "=" + "\n" + "1" + "\n"); +if (x !== 1) { + $ERROR('#4: eval("\\n" + "var" + "\\n" + "x" + "\\n" + "=" + "\\n" + "1" + "\\n"); x === 1. Actual: ' + (x)); +} + +//CHECK#5 +eval("\u000A" + "var" + "\n" + "x" + "\u000A" + "=" + "\n" + "1" + "\u000A"); +if (x !== 1) { + $ERROR('#5: eval("\\u000A" + "var" + "\\n" + "x" + "\\u000A" + "=" + "\\n" + "1" + "\\u000A"); x === 1. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.1_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.1_T2.js new file mode 100644 index 000000000..8e836e261 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.1_T2.js @@ -0,0 +1,18 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A1.1_T2; + * @section: 7.3; + * @assertion: LINE FEED (U+000A) may occur between any two tokens; + * @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)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.2_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.2_T1.js new file mode 100644 index 000000000..a276eba81 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.2_T1.js @@ -0,0 +1,39 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A1.2_T1; + * @section: 7.3; + * @assertion: CARRIAGE RETURN (U+000D) may occur between any two tokens; + * @description: Insert CARRIAGE RETURN (\u000D and \r) between tokens of var x=1; +*/ + +// CHECK#1 +eval("\u000Dvar\u000Dx\u000D=\u000D1\u000D"); +if (x !== 1) { + $ERROR('#1: eval("\\u000Dvar\\u000Dx\\u000D=\\u000D1\\u000D"); x === 1. Actual: ' + (x)); +} + +//CHECK#2 +eval("\u000D" + "var" + "\u000D" + "x" + "\u000D" + "=" + "\u000D" + "1" + "\u000D"); +if (x !== 1) { + $ERROR('#2: eval("\\u000D" + "var" + "\\u000D" + "x" + "\\u000D" + "=" + "\\u000D" + "1" + "\\u000D"); x === 1. Actual: ' + (x)); +} + +//CHECK#3 +eval("\rvar\rx\r=\r1\r"); +if (x !== 1) { + $ERROR('#3: eval("\\rvar\\rx\\r=\\r1\\r"); x === 1. Actual: ' + (x)); +} + +//CHECK#4 +eval("\r" + "var" + "\r" + "x" + "\r" + "=" + "\r" + "1" + "\r"); +if (x !== 1) { + $ERROR('#4: eval("\\r" + "var" + "\\r" + "x" + "\\r" + "=" + "\\r" + "1" + "\\r"); x === 1. Actual: ' + (x)); +} + +//CHECK#5 +eval("\u000D" + "var" + "\r" + "x" + "\u000D" + "=" + "\r" + "1" + "\u000D"); +if (x !== 1) { + $ERROR('#5: eval("\\u000D" + "var" + "\\r" + "x" + "\\u000D" + "=" + "\\r" + "1" + "\\u000D"); x === 1. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.2_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.2_T2.js new file mode 100644 index 000000000..ee5bae510 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.2_T2.js @@ -0,0 +1,11 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A1.2_T2; + * @section: 7.3; + * @assertion: CARRIAGE RETURN (U+000D) may occur between any two tokens; + * @description: Insert real CARRIAGE RETURN 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));
} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.3.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.3.js new file mode 100644 index 000000000..87d19250a --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.3.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. + +/** + * @name: S7.3_A1.3; + * @section: 7.3; + * @assertion: LINE SEPARATOR (U+2028) may occur between any two tokens; + * @description: Insert LINE SEPARATOR (\u2028) between tokens of var x=1; +*/ + +// CHECK#1 +eval("\u2028var\u2028x\u2028=\u20281\u2028"); +if (x !== 1) { + $ERROR('#1: eval("\\u2028var\\u2028x\\u2028=\\u20281\\u2028"); x === 1. Actual: ' + (x)); +} + +//CHECK#2 +eval("\u2028" + "var" + "\u2028" + "x" + "\u2028" + "=" + "\u2028" + "1" + "\u2028"); +if (x !== 1) { + $ERROR('#2: eval("\\u2028" + "var" + "\\u2028" + "x" + "\\u2028" + "=" + "\\u2028" + "1" + "\\u2028"); x === 1. Actual: ' + (x)); +} + diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.4.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.4.js new file mode 100644 index 000000000..8a5778d5b --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A1.4.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. + +/** + * @name: S7.3_A1.4; + * @section: 7.3; + * @assertion: PARAGRAPH SEPARATOR (U+2029) may occur between any two tokens; + * @description: Insert PARAGRAPH SEPARATOR (\u2029) between tokens of var x=1; +*/ + +// CHECK#1 +eval("\u2029var\u2029x\u2029=\u20291\u2029"); +if (x !== 1) { + $ERROR('#1: eval("\\u2029var\\u2029x\\u2029=\\u20291\\u2029"); x === 1. Actual: ' + (x)); +} + +//CHECK#2 +eval("\u2029" + "var" + "\u2029" + "x" + "\u2029" + "=" + "\u2029" + "1" + "\u2029"); +if (x !== 1) { + $ERROR('#2: eval("\\u2029" + "var" + "\\u2029" + "x" + "\\u2029" + "=" + "\\u2029" + "1" + "\\u2029"); x === 1. Actual: ' + (x)); +} + + + diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.1_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.1_T1.js new file mode 100644 index 000000000..0b5003c13 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.1_T1.js @@ -0,0 +1,15 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A2.1_T1; + * @section: 7.3; + * @assertion: LINE FEED (U+000A) within strings is not allowed; + * @description: Insert LINE FEED (\u000A) into string; + * @negative +*/ + +// CHECK#1 +if (eval("'\u000Astr\u000Aing\u000A'") === "\u000Astr\u000Aing\u000A") { + $ERROR('#1: eval("\'\\u000Astr\\u000Aing\\u000A\'") === "\\u000Astr\\u000Aing\\u000A"'); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.1_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.1_T2.js new file mode 100644 index 000000000..64bb1b6c5 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.1_T2.js @@ -0,0 +1,16 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A2.1_T2; + * @section: 7.3; + * @assertion: LINE FEED (U+000A) within strings is not allowed; + * @description: Use real LINE FEED into string; + * @negative +*/ + +//CHECK#1 +" +str +ing +"; diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.2_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.2_T1.js new file mode 100644 index 000000000..695640178 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.2_T1.js @@ -0,0 +1,15 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A2.2_T1; + * @section: 7.3; + * @assertion: CARRIAGE RETURN (U+000D) within strings is not allowed; + * @description: Insert CARRIAGE RETURN (\u000D) into string; + * @negative +*/ + +// CHECK#1 +if (eval("'\u000Dstr\u000Ding\u000D'") === "\u000Dstr\u000Ding\u000D") { + $ERROR('#1: eval("\'\\u000Dstr\\u000Ding\\u000D\'") === "\\u000Dstr\\u000Ding\\u000D"'); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.2_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.2_T2.js new file mode 100644 index 000000000..a3f465c95 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.2_T2.js @@ -0,0 +1,11 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A2.2_T2; + * @section: 7.3; + * @assertion: CARRIAGE RETURN (U+000D) within strings is not allowed; + * @description: Insert real CARRIAGE RETURN into string; + * @negative +*/ +
//CHECK#1
"
str
ing
"; diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.3.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.3.js new file mode 100644 index 000000000..24da21330 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.3.js @@ -0,0 +1,15 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A2.3; + * @section: 7.3; + * @assertion: LINE SEPARATOR (U+2028) within strings is not allowed; + * @description: Insert LINE SEPARATOR (\u2028) into string; + * @negative +*/ + +// CHECK#1 +if (eval("'\u2028str\u2028ing\u2028'") === "\u2028str\u2028ing\u2028") { + $ERROR('#1: eval("\'\\u2028str\\u2028ing\\u2028\'") === "\\u2028str\\u2028ing\\u2028"'); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.4.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.4.js new file mode 100644 index 000000000..5979695f1 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A2.4.js @@ -0,0 +1,15 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A2.4; + * @section: 7.3; + * @assertion: PARAGRAPH SEPARATOR (U+2029) within strings is not allowed; + * @description: Insert PARAGRAPH SEPARATOR (\u2029) into string; + * @negative +*/ + +// CHECK#1 +if (eval("'\u2029str\u2029ing\u2029'") === "\u2029str\u2029ing\u2029") { + $ERROR('#1: eval("\'\\u2029str\\u2029ing\\u2029\'") === "\\u2029str\\u2029ing\\u2029"'); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T1.js new file mode 100644 index 000000000..4a21470a3 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T1.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.1_T1;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain LINE FEED (U+000A) inside;
* @description: Insert LINE FEED (\u000A) into single line comment;
* @negative
*/
// CHECK#1
eval("// single line \u000A comment"); diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T2.js new file mode 100644 index 000000000..e8d809565 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T2.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.1_T2;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain LINE FEED (U+000A) inside;
* @description: Insert LINE FEED (\u000A) into begin of single line comment;
* @negative
*/
// CHECK#1
eval("//\u000A single line comment"); diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T3.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T3.js new file mode 100644 index 000000000..07eb842f9 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.1_T3.js @@ -0,0 +1,7 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.1_T3;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain LINE FEED (U+000A) inside;
* @description: Insert real LINE FEED into single line comment;
* @negative
*/ +// CHECK#1 +//single +line comment diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T1.js new file mode 100644 index 000000000..1bf2c0c0b --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T1.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.2_T1;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain CARRIAGE RETURN (U+000D) inside;
* @description: Insert CARRIAGE RETURN (\u000D) into single line comment;
* @negative
*/
// CHECK#1
eval("// single line \u000D comment"); diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T2.js new file mode 100644 index 000000000..95a1308b1 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T2.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.2_T2;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain CARRIAGE RETURN (U+000D) inside;
* @description: Insert CARRIAGE RETURN (\u000D) into begin of single line comment;
* @negative
*/
// CHECK#1
eval("//\u000D single line comment"); diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T3.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T3.js new file mode 100644 index 000000000..16fb279dc --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.2_T3.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.2_T3;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain CARRIAGE RETURN (U+000D) inside;
* @description: Insert real CARRIAGE RETURN into single line comment;
* @negative
*/
// CHECK#1
//single
line comment diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.3_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.3_T1.js new file mode 100644 index 000000000..b4e51a34e --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.3_T1.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.3_T1;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain LINE SEPARATOR (U+2028) inside;
* @description: Insert LINE SEPARATOR (\u2028) into single line comment;
* @negative
*/
// CHECK#1
eval("// single line \u2028 comment"); diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.3_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.3_T2.js new file mode 100644 index 000000000..4c7a7bf6d --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.3_T2.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.3_T2;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain LINE SEPARATOR (U+2028) inside;
* @description: Insert LINE SEPARATOR (\u2028) into begin of single line comment;
* @negative
*/
// CHECK#1
eval("//\u2028 single line comment"); diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.4_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.4_T1.js new file mode 100644 index 000000000..495f308ee --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.4_T1.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.4_T1;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain PARAGRAPH SEPARATOR (U+2029) inside;
* @description: Insert PARAGRAPH SEPARATOR (\u2029) into single line comment;
* @negative
*/
// CHECK#1
eval("// single line \u2029 comment"); diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.4_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.4_T2.js new file mode 100644 index 000000000..6018b2b3d --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A3.4_T2.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A3.4_T2;
* @section: 7.3, 7.4;
* @assertion: Single line comments can not contain PARAGRAPH SEPARATOR (U+2029) inside;
* @description: Insert PARAGRAPH SEPARATOR (\u2029) into begin of single line comment;
* @negative
*/
// CHECK#1
eval("//\u2029 single line comment"); diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T1.js new file mode 100644 index 000000000..d2f6b53f0 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T1.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A4_T1;
* @section: 7.3, 7.4;
* @assertion: Single line comments can contain Line Terminator at the end of line;
* @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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T2.js new file mode 100644 index 000000000..362248471 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T2.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A4_T2;
* @section: 7.3, 7.4;
* @assertion: Single line comments can contain Line Terminator at the end of line;
* @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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T3.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T3.js new file mode 100644 index 000000000..3494d9a3b --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T3.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A4_T3;
* @section: 7.3, 7.4;
* @assertion: Single line comments can contain Line Terminator at the end of line;
* @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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T4.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T4.js new file mode 100644 index 000000000..07071c1d5 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A4_T4.js @@ -0,0 +1,4 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/**
* @name: S7.3_A4_T4;
* @section: 7.3, 7.4;
* @assertion: Single line comments can contain Line Terminator at the end of line;
* @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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.1_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.1_T1.js new file mode 100644 index 000000000..f0422188b --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.1_T1.js @@ -0,0 +1,19 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A5.1_T1; + * @section: 7.3, 7.4; + * @assertion: Multi line comment can contain LINE FEED (U+000A); + * @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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.1_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.1_T2.js new file mode 100644 index 000000000..0b7fe7aba --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.1_T2.js @@ -0,0 +1,21 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A5.1_T2; + * @section: 7.3, 7.4; + * @assertion: Multi line comment can contain LINE FEED (U+000A); + * @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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.2_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.2_T1.js new file mode 100644 index 000000000..ac4b48f0e --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.2_T1.js @@ -0,0 +1,19 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A5.2_T1; + * @section: 7.3, 7.4; + * @assertion: Multi line comment can contain CARRIAGE RETURN (U+000D); + * @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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.2_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.2_T2.js new file mode 100644 index 000000000..7bc6810c9 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.2_T2.js @@ -0,0 +1,10 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A5.2_T2; + * @section: 7.3, 7.4; + * @assertion: Multi line comment can contain CARRIAGE RETURN (U+000D); + * @description: Insert real CARRIAGE RETURN into multi line comment; + */ +
/*CHECK#1*/
var x = 0;
/*
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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.3.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.3.js new file mode 100644 index 000000000..a48fafa1a --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.3.js @@ -0,0 +1,19 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A5.3; + * @section: 7.3, 7.4; + * @assertion: Multi line comment can contain LINE SEPARATOR (U+2028); + * @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/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.4.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.4.js new file mode 100644 index 000000000..d675e9bab --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A5.4.js @@ -0,0 +1,19 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A5.4; + * @section: 7.3, 7.4; + * @assertion: Multi line comment can contain LINE SEPARATOR (U+2029); + * @description: Insert PARAGRAPH SEPARATOR (U+2029) into multi line comment; + */ + +// CHECK#1 +eval("/*\u2029 multi line \u2029 comment \u2029*/"); + +//CHECK#2 +var x = 0; +eval("/*\u2029 multi line \u2029 comment \u2029 x = 1;*/"); +if (x !== 0) { + $ERROR('#1: var x = 0; eval("/*\\u2029 multi line \\u2029 comment \\u2029 x = 1;*/"); x === 0. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T1.js new file mode 100644 index 000000000..c143b701f --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T1.js @@ -0,0 +1,12 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A6_T1; + * @section: 7.3; + * @assertion: Line Terminator cannot be expressed as a Unicode escape sequence consisting of six characters, namely \u plus four hexadecimal digits; + * @description: Insert LINE FEED (U+000A) in var x; + * @negative +*/ + +var\u000Ax; diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T2.js new file mode 100644 index 000000000..88f5dcf1b --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T2.js @@ -0,0 +1,12 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A6_T2; + * @section: 7.3; + * @assertion: Line Terminator cannot be expressed as a Unicode escape sequence consisting of six characters, namely \u plus four hexadecimal digits; + * @description: Insert CARRIAGE RETURN (U+000D) in var x; + * @negative +*/ + +var\u000Dx; diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T3.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T3.js new file mode 100644 index 000000000..5e19cdf28 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T3.js @@ -0,0 +1,12 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A6_T3; + * @section: 7.3; + * @assertion: Line Terminator cannot be expressed as a Unicode escape sequence consisting of six characters, namely \u plus four hexadecimal digits; + * @description: Insert LINE SEPARATOR (U+2028) in var x; + * @negative +*/ + +var\u2028x; diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T4.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T4.js new file mode 100644 index 000000000..1caba1434 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A6_T4.js @@ -0,0 +1,12 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A6_T4; + * @section: 7.3; + * @assertion: Line Terminator cannot be expressed as a Unicode escape sequence consisting of six characters, namely \u plus four hexadecimal digits; + * @description: Insert PARAGRAPH SEPARATOR (U+2029) in var x; + * @negative +*/ + +var\u2029x; diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T1.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T1.js new file mode 100644 index 000000000..e92c67eb1 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T1.js @@ -0,0 +1,56 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A7_T1; + * @section: 7.3; + * @assertion: Line Terminators between operators are allowed; + * @description: Insert Line Terminator in var x=y+z; +*/ + +// CHECK#1 +var y=2; +var z=3; +var +x += +y ++ +z +; +if (x !== 5) { + $ERROR('#1: var\\nx\\n=\\ny\\n+\\nz\\n; x === 5. Actual: ' + (x)); +} +x=0; + +// CHECK#2 +var y=2; +var z=3; +var +x += +y ++ +z +; +if (x !== 5) { + $ERROR('#2: var\\nx\\n=\\ny\\n+\\nz\\n; x === 5. Actual: ' + (x)); +} +x=0; + +// CHECK#3 +var y=2; +var z=3; +eval("\u2028var\u2028x\u2028=\u2028y\u2028+\u2028z\u2028"); +if (x !== 5) { + $ERROR('#3: eval("\\u2028var\\u2028x\\u2028=\\u2028y\\u2028+\\u2028z\\u2028"); x === 5. Actual: ' + (x)); +} +x=0; + +// CHECK#4 +var y=2; +var z=3; +eval("\u2029var\u2029x\u2029=\u2029y\u2029+\u2029z\u2029"); +if (x !== 5) { + $ERROR('#4: eval("\\u2029var\\u2029x\\u2029=\\u2029y\\u2029+\\u2029z\\u2029"); x === 5. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T2.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T2.js new file mode 100644 index 000000000..050a95a85 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T2.js @@ -0,0 +1,56 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A7_T2; + * @section: 7.3; + * @assertion: Line Terminators between operators are allowed; + * @description: Insert Line Terminator in var x=y-z; +*/ + +// CHECK#1 +var y=3; +var z=2; +var +x += +y +- +z +; +if (x !== 1) { + $ERROR('#1: var\\nx\\n=\\ny\\n-\\nz\\n; x === 1. Actual: ' + (x)); +} +x=0; + +// CHECK#2 +var y=3; +var z=2; +var +x += +y +- +z +; +if (x !== 1) { + $ERROR('#2: var\\nx\\n=\\ny\\n-\\nz\\n; x === 1. Actual: ' + (x)); +} +x=0; + +// CHECK#3 +var y=3; +var z=2; +eval("\u2028var\u2028x\u2028=\u2028y\u2028-\u2028z\u2028"); +if (x !== 1) { + $ERROR('#3: eval("\\u2028var\\u2028x\\u2028=\\u2028y\\u2028-\\u2028z\\u2028"); x === 1. Actual: ' + (x)); +} +x=0; + +// CHECK#4 +var y=3; +var z=2; +eval("\u2029var\u2029x\u2029=\u2029y\u2029-\u2029z\u2029"); +if (x !== 1) { + $ERROR('#4: eval("\\u2029var\\u2029x\\u2029=\\u2029y\\u2029-\\u2029z\\u2029"); x === 1. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T3.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T3.js new file mode 100644 index 000000000..536ee9173 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T3.js @@ -0,0 +1,56 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A7_T3; + * @section: 7.3; + * @assertion: Line Terminators between operators are allowed; + * @description: Insert Line Terminator in var x=y*z; +*/ + +// CHECK#1 +var y=3; +var z=2; +var +x += +y +* +z +; +if (x !== 6) { + $ERROR('#1: var\\nx\\n=\\ny\\n*\\nz\\n; x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#2 +var y=3; +var z=2; +var +x += +y +* +z +; +if (x !== 6) { + $ERROR('#2: var\\nx\\n=\\ny\\n*\\nz\\n; x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#3 +var y=3; +var z=2; +eval("\u2028var\u2028x\u2028=\u2028y\u2028*\u2028z\u2028"); +if (x !== 6) { + $ERROR('#3: eval("\\u2028var\\u2028x\\u2028=\\u2028y\\u2028*\\u2028z\\u2028"); x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#4 +var y=3; +var z=2; +eval("\u2029var\u2029x\u2029=\u2029y\u2029*\u2029z\u2029"); +if (x !== 6) { + $ERROR('#4: eval("\\u2029var\\u2029x\\u2029=\\u2029y\\u2029*\\u2029z\\u2029"); x === 6. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T4.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T4.js new file mode 100644 index 000000000..c1e84b5db --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T4.js @@ -0,0 +1,56 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A7_T4; + * @section: 7.3; + * @assertion: Line Terminators between operators are allowed; + * @description: Insert Line Terminator in var x=y/z; +*/ + +// CHECK#1 +var y=12; +var z=2; +var +x += +y +/ +z +; +if (x !== 6) { + $ERROR('#1: var\\nx\\n=\\ny\\n/\\nz\\n; x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#2 +var y=12; +var z=2; +var +x += +y +/ +z +; +if (x !== 6) { + $ERROR('#2: var\\nx\\n=\\ny\\n/\\nz\\n; x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#3 +var y=12; +var z=2; +eval("\u2028var\u2028x\u2028=\u2028y\u2028/\u2028z\u2028"); +if (x !== 6) { + $ERROR('#3: eval("\\u2028var\\u2028x\\u2028=\\u2028y\\u2028/\\u2028z\\u2028"); x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#4 +var y=12; +var z=2; +eval("\u2029var\u2029x\u2029=\u2029y\u2029/\u2029z\u2029"); +if (x !== 6) { + $ERROR('#4: eval("\\u2029var\\u2029x\\u2029=\\u2029y\\u2029/\\u2029z\\u2029"); x === 6. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T5.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T5.js new file mode 100644 index 000000000..132caa73d --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T5.js @@ -0,0 +1,56 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A7_T5; + * @section: 7.3; + * @assertion: Line Terminators between operators are allowed; + * @description: Insert Line Terminator in var x=y%z; +*/ + +// CHECK#1 +var y=16; +var z=10; +var +x += +y +% +z +; +if (x !== 6) { + $ERROR('#1: var\\nx\\n=\\ny\\n%\\nz\\n; x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#2 +var y=16; +var z=10; +var +x += +y +% +z +; +if (x !== 6) { + $ERROR('#2: var\\nx\\n=\\ny\\n%\\nz\\n; x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#3 +var y=16; +var z=10; +eval("\u2028var\u2028x\u2028=\u2028y\u2028%\u2028z\u2028"); +if (x !== 6) { + $ERROR('#3: eval("\\u2028var\\u2028x\\u2028=\\u2028y\\u2028%\\u2028z\\u2028"); x === 6. Actual: ' + (x)); +} +x=0; + +// CHECK#4 +var y=16; +var z=10; +eval("\u2029var\u2029x\u2029=\u2029y\u2029%\u2029z\u2029"); +if (x !== 6) { + $ERROR('#4: eval("\\u2029var\\u2029x\\u2029=\\u2029y\\u2029%\\u2029z\\u2029"); x === 6. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T6.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T6.js new file mode 100644 index 000000000..f4c326ff9 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T6.js @@ -0,0 +1,56 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A7_T6; + * @section: 7.3; + * @assertion: Line Terminators between operators are allowed; + * @description: Insert Line Terminator in var x=y>>z; +*/ + +// CHECK#1 +var y=16; +var z=3; +var +x += +y +>> +z +; +if (x !== 2) { + $ERROR('#1: var\\nx\\n=\\ny\\n>>\\nz\\n; x === 2. Actual: ' + (x)); +} +x=0; + +// CHECK#2 +var y=16; +var z=3; +var +x += +y +>> +z +; +if (x !== 2) { + $ERROR('#2: var\\nx\\n=\\ny\\n>>\\nz\\n; x === 2. Actual: ' + (x)); +} +x=0; + +// CHECK#3 +var y=16; +var z=3; +eval("\u2028var\u2028x\u2028=\u2028y\u2028>>\u2028z\u2028"); +if (x !== 2) { + $ERROR('#3: eval("\\u2028var\\u2028x\\u2028=\\u2028y\\u2028>>\\u2028z\\u2028"); x === 2. Actual: ' + (x)); +} +x=0; + +// CHECK#4 +var y=16; +var z=3; +eval("\u2029var\u2029x\u2029=\u2029y\u2029>>\u2029z\u2029"); +if (x !== 2) { + $ERROR('#4: eval("\\u2029var\\u2029x\\u2029=\\u2029y\\u2029>>\\u2029z\\u2029"); x === 2. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T7.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T7.js new file mode 100644 index 000000000..904727e21 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T7.js @@ -0,0 +1,56 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A7_T7; + * @section: 7.3; + * @assertion: Line Terminators between operators are allowed; + * @description: Insert Line Terminator in var x=y<<z; +*/ + +// CHECK#1 +var y=2; +var z=3; +var +x += +y +<< +z +; +if (x !== 16) { + $ERROR('#1: var\\nx\\n=\\ny\\n<<\\nz\\n; x === 16. Actual: ' + (x)); +} +x=0; + +// CHECK#2 +var y=2; +var z=3; +var +x += +y +<< +z +; +if (x !== 16) { + $ERROR('#2: var\\nx\\n=\\ny\\n<<\\nz\\n; x ===16 '); +} +x=0; + +// CHECK#3 +var y=2; +var z=3; +eval("\u2028var\u2028x\u2028=\u2028y\u2028<<\u2028z\u2028"); +if (x !== 16) { + $ERROR('#3: eval("\\u2028var\\u2028x\\u2028=\\u2028y\\u2028<<\\u2028z\\u2028"); x === 16. Actual: ' + (x)); +} +x=0; + +// CHECK#4 +var y=2; +var z=3; +eval("\u2029var\u2029x\u2029=\u2029y\u2029<<\u2029z\u2029"); +if (x !== 16) { + $ERROR('#4: eval("\\u2029var\\u2029x\\u2029=\\u2029y\\u2029<<\\u2029z\\u2029"); x === 16. Actual: ' + (x)); +} diff --git a/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T8.js b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T8.js new file mode 100644 index 000000000..cc66de3b9 --- /dev/null +++ b/external/contributions/Google/sputniktests/tests/Conformance/07_Lexical_Conventions/7.3_Line_Terminators/S7.3_A7_T8.js @@ -0,0 +1,56 @@ +// Copyright 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/** + * @name: S7.3_A7_T8; + * @section: 7.3; + * @assertion: Line Terminators between operators are allowed; + * @description: Insert Line Terminator in var x=y<z; +*/ + +// CHECK#1 +var y=2; +var z=3; +var +x += +y +< +z +; +if (x !== true) { + $ERROR('#1: var\\nx\\n=\\ny\\n<\\nz\\n; x === true. Actual: ' + (x)); +} +x=0; + +// CHECK#2 +var y=2; +var z=3; +var +x += +y +< +z +; +if (x !== true) { + $ERROR('#2: var\\nx\\n=\\ny\\n<\\nz\\n; x === true. Actual: ' + (x)); +} +x=0; + +// CHECK#3 +var y=2; +var z=3; +eval("\u2028var\u2028x\u2028=\u2028y\u2028<\u2028z\u2028"); +if (x !== true) { + $ERROR('#3: eval("\\u2028var\\u2028x\\u2028=\\u2028y\\u2028<\\u2028z\\u2028"); x === true. Actual: ' + (x)); +} +x=0; + +// CHECK#4 +var y=2; +var z=3; +eval("\u2029var\u2029x\u2029=\u2029y\u2029<\u2029z\u2029"); +if (x !== true) { + $ERROR('#4: eval("\\u2029var\\u2029x\\u2029=\\u2029y\\u2029<\\u2029z\\u2029"); x === true. Actual: ' + (x)); +} |