diff --git a/harness/arrayContains.js b/harness/arrayContains.js index 47af86b8f246ddf4737633a18e5a424c7a4bbfb0..5f758b933a3876931367d96b7b9250f836620331 100644 --- a/harness/arrayContains.js +++ b/harness/arrayContains.js @@ -1,10 +1,16 @@ -//----------------------------------------------------------------------------- -function arrayContains(arr, expected) { +/** + * Verify that a subArray is contained within an array. + * + * @param {Array} array + * @param {Array} subArray + */ + +function arrayContains(array, subArray) { var found; - for (var i = 0; i < expected.length; i++) { + for (var i = 0; i < subArray.length; i++) { found = false; - for (var j = 0; j < arr.length; j++) { - if (expected[i] === arr[j]) { + for (var j = 0; j < array.length; j++) { + if (subArray[i] === array[j]) { found = true; break; } diff --git a/harness/Date_constants.js b/harness/dateConstants.js similarity index 80% rename from harness/Date_constants.js rename to harness/dateConstants.js index 11ce5c7e4c084208b97b1f78c7f1c48dfaad570f..ebf2d75e5480aa38920f56ba76717b9592494311 100644 --- a/harness/Date_constants.js +++ b/harness/dateConstants.js @@ -1,5 +1,4 @@ -//Date_constants.js -// Copyright 2009 the Sputnik authors. All rights reserved. +// Copyright (C) 2009 the Sputnik authors. All rights reserved. // This code is governed by the BSD license found in the LICENSE file. var date_1899_end = -2208988800001; diff --git a/harness/PromiseHelper.js b/harness/promiseHelper.js similarity index 94% rename from harness/PromiseHelper.js rename to harness/promiseHelper.js index 963b93f441071500f31f344a22eddf5894661f26..0bdff33e4481088916b516e3ad46e3a9e76fe789 100644 --- a/harness/PromiseHelper.js +++ b/harness/promiseHelper.js @@ -6,4 +6,6 @@ function checkSequence(arr, message) { " '" + arr.join(',') + "'"); } }); + + return true; } diff --git a/harness/tco-helper.js b/harness/tcoHelper.js similarity index 100% rename from harness/tco-helper.js rename to harness/tcoHelper.js diff --git a/test/built-ins/Date/S15.9.3.2_A1_T1.js b/test/built-ins/Date/S15.9.3.2_A1_T1.js index 88066187c80856bbaccd3b34e87d2fee912265ed..d5aefcf56befa0b886ee15c8b84b7c5f9f058cd5 100644 --- a/test/built-ins/Date/S15.9.3.2_A1_T1.js +++ b/test/built-ins/Date/S15.9.3.2_A1_T1.js @@ -7,8 +7,7 @@ info: > a constructor: it initialises the newly created object es5id: 15.9.3.2_A1_T1 description: Checking types of newly created objects and it values -includes: - - Date_constants.js +includes: [dateConstants.js] ---*/ if (typeof new Date(date_1899_end) !== "object") { diff --git a/test/built-ins/Date/S15.9.3.2_A2_T1.js b/test/built-ins/Date/S15.9.3.2_A2_T1.js index 1312cb05fd9d1583b1cc658d373d30cfe963d179..e8d8f57566827ff4bec9369c48887fcb9ac70029 100644 --- a/test/built-ins/Date/S15.9.3.2_A2_T1.js +++ b/test/built-ins/Date/S15.9.3.2_A2_T1.js @@ -8,8 +8,7 @@ info: > initial value of Date.prototype es5id: 15.9.3.2_A2_T1 description: Checking Date.prototype property of newly constructed objects -includes: - - Date_constants.js +includes: [dateConstants.js] ---*/ var x11 = new Date(date_1899_end); diff --git a/test/built-ins/Date/S15.9.3.2_A3_T1.1.js b/test/built-ins/Date/S15.9.3.2_A3_T1.1.js index 2cf740fd27218c53cc6554c7ed877b3f7de96635..2880a915319bcb3102f372cc32b27551411d4c93 100644 --- a/test/built-ins/Date/S15.9.3.2_A3_T1.1.js +++ b/test/built-ins/Date/S15.9.3.2_A3_T1.1.js @@ -7,8 +7,7 @@ info: > is set to "Date" es5id: 15.9.3.2_A3_T1.1 description: Test based on delete prototype.toString -includes: - - Date_constants.js +includes: [dateConstants.js] ---*/ var x1 = new Date(date_1899_end); diff --git a/test/built-ins/Date/S15.9.3.2_A3_T1.2.js b/test/built-ins/Date/S15.9.3.2_A3_T1.2.js index a12598c7afa441f7f24a39718378f0f74c07effd..af0ce77d043b852b49e3a96abe7998194dd5aaa7 100644 --- a/test/built-ins/Date/S15.9.3.2_A3_T1.2.js +++ b/test/built-ins/Date/S15.9.3.2_A3_T1.2.js @@ -7,8 +7,7 @@ info: > is set to "Date" es5id: 15.9.3.2_A3_T1.2 description: Test based on overwriting prototype.toString -includes: - - Date_constants.js +includes: [dateConstants.js] ---*/ Date.prototype.toString = Object.prototype.toString; diff --git a/test/built-ins/Promise/all/S25.4.4.1_A2.2_T1.js b/test/built-ins/Promise/all/S25.4.4.1_A2.2_T1.js index a34fb70f6d5bd7133afeaaf001a8010d68221075..ddeea876d2cc74aa5fad73eba91dbc48e0b507e1 100644 --- a/test/built-ins/Promise/all/S25.4.4.1_A2.2_T1.js +++ b/test/built-ins/Promise/all/S25.4.4.1_A2.2_T1.js @@ -5,7 +5,7 @@ info: Promise.all([]) is resolved immediately es6id: 25.4.4.1_A2.2_T1 author: Sam Mikes -includes: [PromiseHelper.js] +includes: [promiseHelper.js] description: Promise.all([]) returns immediately flags: [async] ---*/ diff --git a/test/built-ins/Promise/all/S25.4.4.1_A7.2_T1.js b/test/built-ins/Promise/all/S25.4.4.1_A7.2_T1.js index 2ce3ad82a96004ed7e553d82a8a131771fa1542f..acfeafc6d1c877e127c059e5e43d687fe9f6efab 100644 --- a/test/built-ins/Promise/all/S25.4.4.1_A7.2_T1.js +++ b/test/built-ins/Promise/all/S25.4.4.1_A7.2_T1.js @@ -8,7 +8,7 @@ info: > es6id: S25.4.4.1_A7.2_T1 author: Sam Mikes description: Promise.all() accepts a one-element array -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/all/S25.4.4.1_A8.1_T1.js b/test/built-ins/Promise/all/S25.4.4.1_A8.1_T1.js index d9e9cac5a098845daf46610ab11e86b2b1bd7ab2..7a6d917d0e5dee40040e8cb6b74e94abe9cdfe62 100644 --- a/test/built-ins/Promise/all/S25.4.4.1_A8.1_T1.js +++ b/test/built-ins/Promise/all/S25.4.4.1_A8.1_T1.js @@ -5,7 +5,7 @@ es6id: S25.4.4.1_A8.1_T1 author: Sam Mikes description: Promise.all([p1, p2]) resolution functions are called in predictable sequence -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/all/S25.4.4.1_A8.2_T1.js b/test/built-ins/Promise/all/S25.4.4.1_A8.2_T1.js index e8f1320f714fb895ded12c93a92274ffc041d467..8c379cd9079cfdaddc605f30a26f813bf3bf425d 100644 --- a/test/built-ins/Promise/all/S25.4.4.1_A8.2_T1.js +++ b/test/built-ins/Promise/all/S25.4.4.1_A8.2_T1.js @@ -7,7 +7,7 @@ info: > es6id: S25.4.4.1_A8.1_T1 author: Sam Mikes description: Promise.all() rejects when a promise in its array rejects -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/all/S25.4.4.1_A8.2_T2.js b/test/built-ins/Promise/all/S25.4.4.1_A8.2_T2.js index 58151d1405f51edca88a0b085429f7e84d1ebd94..25b26cef77652100096211ce2e1514ad5827c76b 100644 --- a/test/built-ins/Promise/all/S25.4.4.1_A8.2_T2.js +++ b/test/built-ins/Promise/all/S25.4.4.1_A8.2_T2.js @@ -7,7 +7,7 @@ info: > es6id: S25.4.4.1_A8.2_T2 author: Sam Mikes description: Promise.all() rejects when second promise in array rejects -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/prototype/then/S25.4.4_A1.1_T1.js b/test/built-ins/Promise/prototype/then/S25.4.4_A1.1_T1.js index a1c2edcc7e25324ed309ca6f0dca6c4f47f24bb0..33cb988135765864f84c25e1ffdbdad97dbe4997 100644 --- a/test/built-ins/Promise/prototype/then/S25.4.4_A1.1_T1.js +++ b/test/built-ins/Promise/prototype/then/S25.4.4_A1.1_T1.js @@ -8,7 +8,7 @@ info: > es6id: S25.4.2.1_A3.2_T2 author: Sam Mikes description: Promise onResolved functions are called in predictable sequence -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T1.js b/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T1.js index 33c1f555a55e669ea639d69a0476dc42e53cca48..18991506ac41d11861342bd8df4824e664fb46ba 100644 --- a/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T1.js +++ b/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T1.js @@ -9,7 +9,7 @@ info: > es6id: S25.4.4_A2.1_T1 author: Sam Mikes description: Promise onResolved functions are called in predictable sequence -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T2.js b/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T2.js index b5bf2c89e6b82f9701274268cf84c44c32440442..6916e9ce6afc8faf9868e2f72e5ea1b73095ac7a 100644 --- a/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T2.js +++ b/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T2.js @@ -9,7 +9,7 @@ info: > es6id: S25.4.4_A2.1_T2 author: Sam Mikes description: Promise onResolved functions are called in predictable sequence -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T3.js b/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T3.js index 17992e0011e9d85fe25077e163a3255bbd92c68c..c905d8a367fae71c3dc166f9cc93e61a95a5ccbf 100644 --- a/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T3.js +++ b/test/built-ins/Promise/prototype/then/S25.4.4_A2.1_T3.js @@ -9,7 +9,7 @@ info: > es6id: S25.4.4_A2.1_T3 author: Sam Mikes description: Promise onResolved functions are called in predictable sequence -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.1_T1.js b/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.1_T1.js index b97ae3fc9a01d58c47bc4b4286870c576a8e346b..d4fa5562668904eba420b5fd7e98a1018b70e28f 100644 --- a/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.1_T1.js +++ b/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.1_T1.js @@ -8,7 +8,7 @@ info: > es6id: S25.4.5.3_A5.1_T1 author: Sam Mikes description: Promise.prototype.then enqueues handler if pending -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.2_T1.js b/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.2_T1.js index 92ad8b82d4455fb38930e3042efdb8d56c8de483..38e0de93df8f88e7b5274b5cd9109e6441361813 100644 --- a/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.2_T1.js +++ b/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.2_T1.js @@ -8,7 +8,7 @@ info: > es6id: S25.4.5.3_A5.2_T1 author: Sam Mikes description: Promise.prototype.then immediately queues handler if fulfilled -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.3_T1.js b/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.3_T1.js index 27c65f26921ab057b7bdcedc39e1ff1f64d7bc75..c70acedba4783a9073f08c7055d68d6ed388caff 100644 --- a/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.3_T1.js +++ b/test/built-ins/Promise/prototype/then/S25.4.5.3_A5.3_T1.js @@ -8,7 +8,7 @@ info: > es6id: S25.4.5.3_A5.3_T1 author: Sam Mikes description: Promise.prototype.then immediately queues handler if rejected -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/race/S25.4.4.3_A6.1_T1.js b/test/built-ins/Promise/race/S25.4.4.3_A6.1_T1.js index 99c327c5ce0666396c66587a45601c2cb8755112..90c46e37e8274bd05d0b46376f711f7e5c4aa2bd 100644 --- a/test/built-ins/Promise/race/S25.4.4.3_A6.1_T1.js +++ b/test/built-ins/Promise/race/S25.4.4.3_A6.1_T1.js @@ -5,7 +5,7 @@ es6id: S25.4.4.3_A6.1_T1 author: Sam Mikes description: Promise.race([1]) settles immediately -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/race/S25.4.4.3_A6.2_T1.js b/test/built-ins/Promise/race/S25.4.4.3_A6.2_T1.js index 93468f86938a780f058691f709a03a43f0163a08..b28ccdb51617667d6e234a75af343958ed4ee1a7 100644 --- a/test/built-ins/Promise/race/S25.4.4.3_A6.2_T1.js +++ b/test/built-ins/Promise/race/S25.4.4.3_A6.2_T1.js @@ -5,7 +5,7 @@ es6id: S25.4.4.3_A6.2_T1 author: Sam Mikes description: Promise.race([p1]) settles immediately -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/race/S25.4.4.3_A7.1_T1.js b/test/built-ins/Promise/race/S25.4.4.3_A7.1_T1.js index 9f0848429f25d2c3320ba807d6609a56888129a4..517df57b3624393f6a22aaa9bc1fccc48d5da6fb 100644 --- a/test/built-ins/Promise/race/S25.4.4.3_A7.1_T1.js +++ b/test/built-ins/Promise/race/S25.4.4.3_A7.1_T1.js @@ -5,7 +5,7 @@ es6id: S25.4.4.3_A7.1_T1 author: Sam Mikes description: Promise.race([p1, p2]) settles when first settles -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/race/S25.4.4.3_A7.1_T2.js b/test/built-ins/Promise/race/S25.4.4.3_A7.1_T2.js index 6f4030d7d478d70c8cff4d0f9dc06566c83d285a..f0f12a4e5b2e468910eb7e9321821acb148a8d6c 100644 --- a/test/built-ins/Promise/race/S25.4.4.3_A7.1_T2.js +++ b/test/built-ins/Promise/race/S25.4.4.3_A7.1_T2.js @@ -5,7 +5,7 @@ es6id: S25.4.4.3_A7.1_T2 author: Sam Mikes description: Promise.race([p1, p2]) settles when first settles -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/race/S25.4.4.3_A7.1_T3.js b/test/built-ins/Promise/race/S25.4.4.3_A7.1_T3.js index 047dd65d27c3e96111c412f975d5fa778ab23241..7e0f286c847fa1fe4616d839fed68a63f29ed944 100644 --- a/test/built-ins/Promise/race/S25.4.4.3_A7.1_T3.js +++ b/test/built-ins/Promise/race/S25.4.4.3_A7.1_T3.js @@ -5,7 +5,7 @@ es6id: S25.4.4.3_A7.1_T3 author: Sam Mikes description: Promise.race([p1, p2]) settles when first settles -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/race/S25.4.4.3_A7.2_T1.js b/test/built-ins/Promise/race/S25.4.4.3_A7.2_T1.js index fbbdcf95eed3351fa27ad157a31f6a11acfa69d8..3f24b602db1d2f40eda16b4eec7641d327c9d41a 100644 --- a/test/built-ins/Promise/race/S25.4.4.3_A7.2_T1.js +++ b/test/built-ins/Promise/race/S25.4.4.3_A7.2_T1.js @@ -5,7 +5,7 @@ es6id: S25.4.4.3_A7.2_T1 author: Sam Mikes description: Promise.race([p1, p2]) settles when first settles -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/resolve/S25.4.4.5_A3.1_T1.js b/test/built-ins/Promise/resolve/S25.4.4.5_A3.1_T1.js index e76d00a3d9a6dfedc928ede513841a5b500403a1..2a2994a80343705e7fea663162f1baf7a555be6f 100644 --- a/test/built-ins/Promise/resolve/S25.4.4.5_A3.1_T1.js +++ b/test/built-ins/Promise/resolve/S25.4.4.5_A3.1_T1.js @@ -7,7 +7,7 @@ info: > es6id: S25.4.4.5_A3.1_T1 author: Sam Mikes description: Promise.resolve delegates to foreign thenable -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/resolve/S25.Promise_resolve_foreign_thenable_1.js b/test/built-ins/Promise/resolve/S25.Promise_resolve_foreign_thenable_1.js index bf0f2d6d283a9d9b8afb5f65df33b89ab93ceef5..05e712839ef3a93e2b91b7c946962bada1a8e589 100644 --- a/test/built-ins/Promise/resolve/S25.Promise_resolve_foreign_thenable_1.js +++ b/test/built-ins/Promise/resolve/S25.Promise_resolve_foreign_thenable_1.js @@ -7,7 +7,7 @@ info: > es6id: S25.4.4.5 author: Sam Mikes description: Promise.resolve delegates to foreign thenable -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/built-ins/Promise/resolve/S25.Promise_resolve_foreign_thenable_2.js b/test/built-ins/Promise/resolve/S25.Promise_resolve_foreign_thenable_2.js index b4c0c3ec6b29cbf8daf42bfc9cff0f67ebcb7c20..d12cbb2aa1b428f74aa0621412231cdb724c3504 100644 --- a/test/built-ins/Promise/resolve/S25.Promise_resolve_foreign_thenable_2.js +++ b/test/built-ins/Promise/resolve/S25.Promise_resolve_foreign_thenable_2.js @@ -7,7 +7,7 @@ info: > es6id: S25.4.4.5 author: Sam Mikes description: Promise.resolve delegates to foreign thenable -includes: [PromiseHelper.js] +includes: [promiseHelper.js] flags: [async] ---*/ diff --git a/test/harness/arrayContains.js b/test/harness/arrayContains.js new file mode 100644 index 0000000000000000000000000000000000000000..3f83e30878d0040f44198d3a5d0d0250e02bfe4f --- /dev/null +++ b/test/harness/arrayContains.js @@ -0,0 +1,24 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +description: > + Assert that the contents of an array contains another array as a slice or sub-array +includes: [arrayContains.js] +---*/ + +const willMatch = [0, 1, 2]; + +assert(arrayContains([0, 1, 2, 3], willMatch)); +assert(arrayContains([null, 0, 1, 2, 3], willMatch)); +assert(arrayContains([undefined, 0, 1, 2, 3], willMatch)); +assert(arrayContains([false, 0, 1, 2, 3], willMatch)); +assert(arrayContains([NaN, 0, 1, 2, 3], willMatch)); + +const willNotMatch = [1, 0, 2]; + +assert(!arrayContains([1, /* intentional hole */, 2], willNotMatch), '[1, /* intentional hole */, 2], willNotMatch)'); +assert(!arrayContains([1, null, 2], willNotMatch), '[1, null, 2], willNotMatch)'); +assert(!arrayContains([1, undefined, 2], willNotMatch), '[1, undefined, 2], willNotMatch)'); +assert(!arrayContains([1, false, 2], willNotMatch), '[1, false, 2], willNotMatch)'); +assert(!arrayContains([1, NaN, 2], willNotMatch), '[1, NaN, 2], willNotMatch)'); diff --git a/test/harness/dateConstants.js b/test/harness/dateConstants.js new file mode 100644 index 0000000000000000000000000000000000000000..265186aef1fc6178aa2168e8dea06edc76a721b5 --- /dev/null +++ b/test/harness/dateConstants.js @@ -0,0 +1,25 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including dateConstants.js will expose: + + var date_1899_end = -2208988800001; + var date_1900_start = -2208988800000; + var date_1969_end = -1; + var date_1970_start = 0; + var date_1999_end = 946684799999; + var date_2000_start = 946684800000; + var date_2099_end = 4102444799999; + var date_2100_start = 4102444800000; + +includes: [dateConstants.js] +---*/ +assert.sameValue(date_1899_end, -2208988800001); +assert.sameValue(date_1900_start, -2208988800000); +assert.sameValue(date_1969_end, -1); +assert.sameValue(date_1970_start, 0); +assert.sameValue(date_1999_end, 946684799999); +assert.sameValue(date_2000_start, 946684800000); +assert.sameValue(date_2099_end, 4102444799999); +assert.sameValue(date_2100_start, 4102444800000); diff --git a/test/harness/decimalToHexString.js b/test/harness/decimalToHexString.js new file mode 100644 index 0000000000000000000000000000000000000000..5a114a97beba2fb6b6e6000b764a50e03e25d2f9 --- /dev/null +++ b/test/harness/decimalToHexString.js @@ -0,0 +1,26 @@ +// Copyright (C) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +description: > + Including decimalToHexString.js will expose two functions: + + decimalToHexString + decimalToPercentHexString + +includes: [decimalToHexString.js] +---*/ + +assert.sameValue(decimalToHexString(-1), "FFFFFFFF"); +assert.sameValue(decimalToHexString(0.5), "0000"); +assert.sameValue(decimalToHexString(1), "0001"); +assert.sameValue(decimalToHexString(100), "0064"); +assert.sameValue(decimalToHexString(65535), "FFFF"); +assert.sameValue(decimalToHexString(65536), "10000"); + +assert.sameValue(decimalToPercentHexString(-1), "%FF"); +assert.sameValue(decimalToPercentHexString(0.5), "%00"); +assert.sameValue(decimalToPercentHexString(1), "%01"); +assert.sameValue(decimalToPercentHexString(100), "%64"); +assert.sameValue(decimalToPercentHexString(65535), "%FF"); +assert.sameValue(decimalToPercentHexString(65536), "%00"); diff --git a/test/harness/detachArrayBuffer-$262.detachArrayBuffer.js b/test/harness/detachArrayBuffer-$262.detachArrayBuffer.js new file mode 100644 index 0000000000000000000000000000000000000000..2d1d0a433c47a517d92d54205207a33445293333 --- /dev/null +++ b/test/harness/detachArrayBuffer-$262.detachArrayBuffer.js @@ -0,0 +1,42 @@ +// Copyright (C) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including detachArrayBuffer.js will expose a function: + + $DETACHBUFFER + + $DETACHBUFFER relies on the presence of a definition for $262.detachArrayBuffer + +includes: [detachArrayBuffer.js,sta.js] +---*/ + +var $262 = { + detachArrayBuffer() { + throw new Test262Error('$262.detachArrayBuffer called.'); + } +}; + +var ab = new ArrayBuffer(1); +var threw = false; + +try { + $DETACHBUFFER(ab); +} catch(err) { + threw = true; + if (err.constructor !== Test262Error) { + $ERROR( + 'Expected a Test262Error, but a "' + err.constructor.name + + '" was thrown.' + ); + } + if (err.message !== '$262.detachArrayBuffer called.') { + $ERROR(`Expected error message: ${err.message}`); + } +} + +if (threw === false) { + $ERROR('Expected a Test262Error, but no error was thrown.'); +} + + diff --git a/test/harness/detachArrayBuffer.js b/test/harness/detachArrayBuffer.js new file mode 100644 index 0000000000000000000000000000000000000000..22d3b6c11a1a6b7ea3142eaac1e8c5297c1b64ff --- /dev/null +++ b/test/harness/detachArrayBuffer.js @@ -0,0 +1,34 @@ +// Copyright (C) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including detachArrayBuffer.js will expose a function: + + $DETACHBUFFER + + $DETACHBUFFER relies on the presence of a definition for $262.detachArrayBuffer. + Without a definition, calling $DETACHBUFFER will result in a ReferenceError + +includes: [detachArrayBuffer.js,sta.js] +---*/ + +var ab = new ArrayBuffer(1); +var threw = false; + +try { + $DETACHBUFFER(ab); +} catch(err) { + threw = true; + if (err.constructor !== ReferenceError) { + $ERROR( + 'Expected a ReferenceError, but a "' + err.constructor.name + + '" was thrown.' + ); + } +} + +if (threw === false) { + $ERROR('Expected a ReferenceError, but no error was thrown.'); +} + + diff --git a/test/harness/fnGlobalObject.js b/test/harness/fnGlobalObject.js new file mode 100644 index 0000000000000000000000000000000000000000..30198a9f640652e32f220c5d08d19b7f9b38cfbb --- /dev/null +++ b/test/harness/fnGlobalObject.js @@ -0,0 +1,17 @@ +// Copyright (C) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including fnGlobalObject.js will expose a function: + + fnGlobalObject + + fnGlobalObject returns a reference to the global object. + +includes: [fnGlobalObject.js] +---*/ + +var gO = fnGlobalObject(); + +assert(typeof gO === "object"); +assert.sameValue(gO, this); diff --git a/test/harness/nans.js b/test/harness/nans.js new file mode 100644 index 0000000000000000000000000000000000000000..b228838d05ee28e013aaf66669a99e5ae860e7f5 --- /dev/null +++ b/test/harness/nans.js @@ -0,0 +1,18 @@ +// Copyright (C) 2017 Rick Waldron, 2016 the V8 project authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including nans.js will expose: + + var distinctNaNs = [ + 0/0, Infinity/Infinity, -(0/0), Math.pow(-1, 0.5), -Math.pow(-1, 0.5) + ]; + +includes: [nans.js] +---*/ + +assert.sameValue(Number.isNaN(distinctNaNs[0]), true); +assert.sameValue(Number.isNaN(distinctNaNs[1]), true); +assert.sameValue(Number.isNaN(distinctNaNs[2]), true); +assert.sameValue(Number.isNaN(distinctNaNs[3]), true); +assert.sameValue(Number.isNaN(distinctNaNs[4]), true); diff --git a/test/harness/promiseHelper.js b/test/harness/promiseHelper.js new file mode 100644 index 0000000000000000000000000000000000000000..59e8b66991a9ca98ab6cb2f9c7339cb12dbebd7f --- /dev/null +++ b/test/harness/promiseHelper.js @@ -0,0 +1,35 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including promiseHelper.js will expose a function: + + checkSequence + + To ensure execution order of some async chain, checkSequence accepts an array + of numbers, each added during some operation, and verifies that they + are in numeric order. + +includes: [promiseHelper.js,sta.js] +---*/ + +assert(checkSequence([1, 2, 3, 4, 5])); + +var threw = false; + +try { + checkSequence([2, 1, 3, 4, 5]); +} catch(err) { + threw = true; + if (err.constructor !== Test262Error) { + $ERROR( + 'Expected a Test262Error, but a "' + err.constructor.name + + '" was thrown.' + ); + } +} + +if (threw === false) { + $ERROR('Expected a Test262Error, but no error was thrown.'); +} + diff --git a/test/harness/error.js b/test/harness/sta-error.js similarity index 100% rename from test/harness/error.js rename to test/harness/sta-error.js diff --git a/test/harness/sta-override-error.js b/test/harness/sta-override-error.js new file mode 100644 index 0000000000000000000000000000000000000000..840470b13c5110a75be68057727c2f9ccac5395d --- /dev/null +++ b/test/harness/sta-override-error.js @@ -0,0 +1,23 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +description: > + Including sta.js will expose two functions: + + Test262Error + $ERROR + + Assert that global $ERROR is overridable +includes: [sta.js] +---*/ +function BaloneyError() {} + +// Override $ERROR +$ERROR = function() { + throw new BaloneyError(); +}; + +assert.throws(BaloneyError, function() { + $ERROR(); +}); diff --git a/test/harness/sta.js b/test/harness/sta.js new file mode 100644 index 0000000000000000000000000000000000000000..d439f202947eb18b60b4db28860a3bb31064f8e0 --- /dev/null +++ b/test/harness/sta.js @@ -0,0 +1,15 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including sta.js will expose two functions: + + Test262Error + $ERROR + +includes: [sta.js] +---*/ + +assert(typeof Test262Error === "function"); +assert(typeof Test262Error.prototype.toString === "function"); +assert(typeof $ERROR === "function"); diff --git a/test/harness/tcoHelper.js b/test/harness/tcoHelper.js new file mode 100644 index 0000000000000000000000000000000000000000..0f3a0eeee1535a9a74553a27b9d43f4d838a6883 --- /dev/null +++ b/test/harness/tcoHelper.js @@ -0,0 +1,17 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including tcoHelper.js will expose: + + var $MAX_ITERATIONS = 100000; + + This defines the number of consecutive recursive function calls that must be + made in order to prove that stack frames are properly destroyed according to + ES2015 tail call optimization semantics. + +includes: [tcoHelper.js] +---*/ + + +assert.sameValue($MAX_ITERATIONS, 100000); diff --git a/test/harness/testTypedArray-conversions-call-error.js b/test/harness/testTypedArray-conversions-call-error.js new file mode 100644 index 0000000000000000000000000000000000000000..20837bed2ac62dc444f4d9968d4d8240cd6d4c7e --- /dev/null +++ b/test/harness/testTypedArray-conversions-call-error.js @@ -0,0 +1,29 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including testTypedArray.js will expose: + + testTypedArrayConversions() + +includes: [testTypedArray.js] +---*/ +var threw = false; + +try { + testTypedArrayConversions({}, () => {}); +} catch(err) { + threw = true; + if (err.constructor !== TypeError) { + throw new Error( + 'Expected a TypeError, but a "' + err.constructor.name + + '" was thrown.' + ); + } +} + +if (threw === false) { + $ERROR('Expected a TypeError, but no error was thrown.'); +} + + diff --git a/test/harness/testTypedArray-conversions.js b/test/harness/testTypedArray-conversions.js new file mode 100644 index 0000000000000000000000000000000000000000..05a44c552aa9e4c61901f675424c3533eeb4ee7d --- /dev/null +++ b/test/harness/testTypedArray-conversions.js @@ -0,0 +1,54 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including testTypedArray.js will expose: + + testTypedArrayConversions() + +includes: [testTypedArray.js] +---*/ +var callCount = 0; +var bcv = { + values: [ + 127, + ], + expected: { + Int8: [ + 127, + ], + Uint8: [ + 127, + ], + Uint8Clamped: [ + 127, + ], + Int16: [ + 127, + ], + Uint16: [ + 127, + ], + Int32: [ + 127, + ], + Uint32: [ + 127, + ], + Float32: [ + 127, + ], + Float64: [ + 127, + ] + } +}; + +testTypedArrayConversions(bcv, function(TA, value, expected, initial) { + var sample = new TA([initial]); + sample.fill(value); + assert.sameValue(initial, 0); + assert.sameValue(sample[0], expected); + callCount++; +}); + diff --git a/test/harness/testTypedArray.js b/test/harness/testTypedArray.js new file mode 100644 index 0000000000000000000000000000000000000000..ffb6e9e3b7ec3827603e365b645d152e5dc926e4 --- /dev/null +++ b/test/harness/testTypedArray.js @@ -0,0 +1,39 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including testTypedArray.js will expose: + + var typedArrayConstructors = [ array of TypedArray constructors ] + var TypedArray + + testWithTypedArrayConstructors() + testTypedArrayConversions() + +includes: [testTypedArray.js,arrayContains.js] +---*/ +var TAConstructors = [ + Float64Array, + Float32Array, + Int32Array, + Int16Array, + Int8Array, + Uint32Array, + Uint16Array, + Uint8Array, + Uint8ClampedArray +]; +var length = TAConstructors.length; + +assert( + arrayContains(typedArrayConstructors, TAConstructors), + "All TypedArray constructors are accounted for" +); +assert(typeof TypedArray === "function"); +assert.sameValue(TypedArray, Object.getPrototypeOf(Uint8Array)); + + +var callCount = 0; +testWithTypedArrayConstructors(() => callCount++); +assert.sameValue(callCount, length); + diff --git a/test/harness/timer.js b/test/harness/timer.js new file mode 100644 index 0000000000000000000000000000000000000000..911963dcf614eb34a5b9aa25ee696f790891e204 --- /dev/null +++ b/test/harness/timer.js @@ -0,0 +1,18 @@ +// Copyright (c) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +description: > + Including timer.js will expose: + + setTimeout() + +includes: [timer.js,fnGlobalObject.js] +---*/ + +var gO = fnGlobalObject(); + +assert(typeof setTimeout === "function"); +assert(typeof gO.setTimeout === "function"); +assert.sameValue(gO.setTimeout, setTimeout); + +// TODO: assert semantics diff --git a/test/harness/verifyProperty-value-error.js b/test/harness/verifyProperty-value-error.js new file mode 100644 index 0000000000000000000000000000000000000000..84adbe2df4bc28b16c407bcf1d30bf971e207d07 --- /dev/null +++ b/test/harness/verifyProperty-value-error.js @@ -0,0 +1,39 @@ +// Copyright (C) 2017 Rick Waldron. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. + +/*--- +description: > + Including propertyHelper.js will expose: + + verifyProperty() + ... + +includes: [propertyHelper.js,sta.js] +---*/ + +var threw = false; +var object = Object.defineProperty({}, "prop", { + value: 1 +}); + +try { + verifyProperty(object, "prop", { + value: 2 + }); +} catch(err) { + threw = true; + if (err.constructor !== Test262Error) { + throw new Error( + 'Expected a Test262Error, but a "' + err.constructor.name + + '" was thrown.' + ); + } + + if (err.message !== 'descriptor value should be 2 Expected SameValue(«1», «0») to be true') { + $ERROR('The error thrown did not define the specified message.'); + } +} + +if (threw === false) { + $ERROR('Expected a Test262Error, but no error was thrown.'); +} diff --git a/test/language/expressions/call/tco-call-args.js b/test/language/expressions/call/tco-call-args.js index a522abf526145d31a111bd9cf2001f81ff8babba..b18641651ad9ec8abe2a076f4e2d07a2a0d7976c 100644 --- a/test/language/expressions/call/tco-call-args.js +++ b/test/language/expressions/call/tco-call-args.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/expressions/call/tco-member-args.js b/test/language/expressions/call/tco-member-args.js index 40d89c17600c87fe764acb5ebc475911f18915f8..24b35741c666f31a089653e722008ca5848cdaa3 100644 --- a/test/language/expressions/call/tco-member-args.js +++ b/test/language/expressions/call/tco-member-args.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/expressions/comma/tco-final.js b/test/language/expressions/comma/tco-final.js index 9a892d13762611ca97c790d7c2d681f908a09c16..395c28e121d8a034d915c7dc679634ecbfa2ef44 100644 --- a/test/language/expressions/comma/tco-final.js +++ b/test/language/expressions/comma/tco-final.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/expressions/conditional/tco-cond.js b/test/language/expressions/conditional/tco-cond.js index cfad71245dba8f187268889c28f4309b9d7befea..b43251c9eab39dcb0fcde019d4ef588397bcc069 100644 --- a/test/language/expressions/conditional/tco-cond.js +++ b/test/language/expressions/conditional/tco-cond.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/expressions/conditional/tco-pos.js b/test/language/expressions/conditional/tco-pos.js index 8fc828a111171783651a42455ca63823a624437c..ea20871216a498e2b25df1f8d07d42089bbc18d8 100644 --- a/test/language/expressions/conditional/tco-pos.js +++ b/test/language/expressions/conditional/tco-pos.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/expressions/logical-and/tco-right.js b/test/language/expressions/logical-and/tco-right.js index 6570ae03afc04bc29954597b700ee20c099e6e7b..7f34dcfdbd858cd9c8b5c532fb766108b93cd8e8 100644 --- a/test/language/expressions/logical-and/tco-right.js +++ b/test/language/expressions/logical-and/tco-right.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/expressions/logical-or/tco-right.js b/test/language/expressions/logical-or/tco-right.js index 7e8608c5e3f8916f768db4acb44aa4921bcad52c..bd2bd1616165644759d3cd5eb00608835995c4af 100644 --- a/test/language/expressions/logical-or/tco-right.js +++ b/test/language/expressions/logical-or/tco-right.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/expressions/tagged-template/tco-call.js b/test/language/expressions/tagged-template/tco-call.js index 05b29e2275359886d246bc5f4f7a0fcd75a20bbd..180f474719eeaa528e156d4aa97aaf24be1ea153 100644 --- a/test/language/expressions/tagged-template/tco-call.js +++ b/test/language/expressions/tagged-template/tco-call.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ (function() { diff --git a/test/language/expressions/tagged-template/tco-member.js b/test/language/expressions/tagged-template/tco-member.js index 2a1d252891de07b476125b822745030278215c00..ea1fbbddc8defccb4e35c503f0215ec4879c81cb 100644 --- a/test/language/expressions/tagged-template/tco-member.js +++ b/test/language/expressions/tagged-template/tco-member.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ (function() { diff --git a/test/language/expressions/tco-pos.js b/test/language/expressions/tco-pos.js index 00cdb885270f7e93133c54ceb783d9e66534270d..83ec0115576c9bf5fa0bd9ec465e2a32f3cef6f3 100644 --- a/test/language/expressions/tco-pos.js +++ b/test/language/expressions/tco-pos.js @@ -5,7 +5,7 @@ description: Expression is a candidate for tail-call optimization. esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/block/tco-stmt-list.js b/test/language/statements/block/tco-stmt-list.js index 8a04d86c5965e59e00f3a8fb1e959b826c470c0a..cda797844e9fc97087cbc1220f36e471e7b4ed27 100644 --- a/test/language/statements/block/tco-stmt-list.js +++ b/test/language/statements/block/tco-stmt-list.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/block/tco-stmt.js b/test/language/statements/block/tco-stmt.js index a8883559521e0f859c5c2f46df7bbff8589132bf..d232faf444ca75ccc28d968d3f7e7626347e7d0f 100644 --- a/test/language/statements/block/tco-stmt.js +++ b/test/language/statements/block/tco-stmt.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/do-while/tco-body.js b/test/language/statements/do-while/tco-body.js index 664a05ee5753554b53ef0744dee75c6f78f3f051..1e55dbf57856280447d3f7f223151697d3721fe6 100644 --- a/test/language/statements/do-while/tco-body.js +++ b/test/language/statements/do-while/tco-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/for/tco-const-body.js b/test/language/statements/for/tco-const-body.js index 238ad15a57891cfc3d730579167b8dc25a252724..2cd919bd2c29ddb0efe566d8867e21235e940ab5 100644 --- a/test/language/statements/for/tco-const-body.js +++ b/test/language/statements/for/tco-const-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/for/tco-let-body.js b/test/language/statements/for/tco-let-body.js index 614b3f08b4535ef50c53f0c427c5736b3d073326..5d13ee4e8062505684ccff245e12685a8f498694 100644 --- a/test/language/statements/for/tco-let-body.js +++ b/test/language/statements/for/tco-let-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/for/tco-lhs-body.js b/test/language/statements/for/tco-lhs-body.js index b6a05b290aca1b5daf6a1a986d7bbe5e85345c96..1ecdaf67567e316f1a2a1b9c01f194f11db69bdd 100644 --- a/test/language/statements/for/tco-lhs-body.js +++ b/test/language/statements/for/tco-lhs-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/for/tco-var-body.js b/test/language/statements/for/tco-var-body.js index c4c8032c9be4cad4fcd87a8cfbc662ac2b0bf1c0..13a11572047c7dfa4ed618bb3d9bdb11b83a502c 100644 --- a/test/language/statements/for/tco-var-body.js +++ b/test/language/statements/for/tco-var-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/if/tco-else-body.js b/test/language/statements/if/tco-else-body.js index 93f6573b03496fe245d298509956b862a0dd6b41..ff3ee9c2d0b130c58ee26d63e5df07651bd1fcb1 100644 --- a/test/language/statements/if/tco-else-body.js +++ b/test/language/statements/if/tco-else-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/if/tco-if-body.js b/test/language/statements/if/tco-if-body.js index a1d9f962262e137d09a084bba5385188201a68e0..7ab6d054bf513e476a671d741d18de8481261d80 100644 --- a/test/language/statements/if/tco-if-body.js +++ b/test/language/statements/if/tco-if-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/labeled/tco.js b/test/language/statements/labeled/tco.js index 2c5ba79499157d788e4731cba97ef35d8802a136..5d059a3542abb20f1a73f45e02c159e6ef03e5d2 100644 --- a/test/language/statements/labeled/tco.js +++ b/test/language/statements/labeled/tco.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/return/tco.js b/test/language/statements/return/tco.js index fadaaa1dfa19cbfc7a4bd31e31295e94e237a5c9..439926f99665ca23b81aa62c2973682f3558f940 100644 --- a/test/language/statements/return/tco.js +++ b/test/language/statements/return/tco.js @@ -5,7 +5,7 @@ description: Expression within statement is a candidate for tail-call optimizati esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/switch/tco-case-body-dflt.js b/test/language/statements/switch/tco-case-body-dflt.js index d4d51b725f329dba5910fd6c4379c90f74e19a2d..449df6b8443a8fefb3a1f948533c460532872d5b 100644 --- a/test/language/statements/switch/tco-case-body-dflt.js +++ b/test/language/statements/switch/tco-case-body-dflt.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/switch/tco-case-body.js b/test/language/statements/switch/tco-case-body.js index aa0a7a6e40347fb1f2a0c1db6d62116259bb1cef..ee23461ddb215a44dfebbd85611e33e9253b8f81 100644 --- a/test/language/statements/switch/tco-case-body.js +++ b/test/language/statements/switch/tco-case-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/switch/tco-dftl-body.js b/test/language/statements/switch/tco-dftl-body.js index f7df595bf6cd9abcf8a5e637635e7fadb4d05fa3..4f1ad1a10e684e742e2ea4c44b114ae157378d11 100644 --- a/test/language/statements/switch/tco-dftl-body.js +++ b/test/language/statements/switch/tco-dftl-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/try/tco-catch-finally.js b/test/language/statements/try/tco-catch-finally.js index 0bfc33f3d8c3b6b10ec64ec57a5f19d7f02d8912..31d1dc67031753c3eeb92fd5cc3eb4534999751e 100644 --- a/test/language/statements/try/tco-catch-finally.js +++ b/test/language/statements/try/tco-catch-finally.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/try/tco-catch.js b/test/language/statements/try/tco-catch.js index ed5fe2479673ca6a5198ae9798daef6376fdb028..7167f632f0aeea0041580b503bcc9270c9fb7fff 100644 --- a/test/language/statements/try/tco-catch.js +++ b/test/language/statements/try/tco-catch.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/try/tco-finally.js b/test/language/statements/try/tco-finally.js index 2cc0836d85ab0c4267f1bc1e8e78e0bd06ded68b..1ee0295faef12c12df2858f122cf71c0dfb3df10 100644 --- a/test/language/statements/try/tco-finally.js +++ b/test/language/statements/try/tco-finally.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0; diff --git a/test/language/statements/while/tco-body.js b/test/language/statements/while/tco-body.js index b897c8087a909203759b026c2ed0996efe947923..0168e5685edff8563525614bbbcd158205568d53 100644 --- a/test/language/statements/while/tco-body.js +++ b/test/language/statements/while/tco-body.js @@ -5,7 +5,7 @@ description: Statement within statement is a candidate for tail-call optimizatio esid: static-semantics-hasproductionintailposition flags: [onlyStrict] features: [tail-call-optimization] -includes: [tco-helper.js] +includes: [tcoHelper.js] ---*/ var callCount = 0;