diff --git a/test/built-ins/String/15.5.5.5.2-1-1.js b/test/built-ins/String/15.5.5.5.2-1-1.js index 7272f6a63c..cd06724907 100644 --- a/test/built-ins/String/15.5.5.5.2-1-1.js +++ b/test/built-ins/String/15.5.5.5.2-1-1.js @@ -9,15 +9,10 @@ es5id: 15.5.5.5.2-1-1 description: > String object supports bracket notation to lookup of data properties -includes: [runTestCase.js] ---*/ -function testcase() { var s = new String("hello world"); s.foo = 1; - if (s["foo"] === 1) { - return true; - } - } -runTestCase(testcase); + +assert.sameValue(s["foo"], 1, 's["foo"]'); diff --git a/test/built-ins/String/15.5.5.5.2-1-2.js b/test/built-ins/String/15.5.5.5.2-1-2.js index 3dcb39432e..b822ef8a34 100644 --- a/test/built-ins/String/15.5.5.5.2-1-2.js +++ b/test/built-ins/String/15.5.5.5.2-1-2.js @@ -7,14 +7,9 @@ info: > notation to look up non numeric property names. es5id: 15.5.5.5.2-1-2 description: String value supports bracket notation to lookup data properties -includes: [runTestCase.js] ---*/ -function testcase() { var s = String("hello world"); - if (s["foo"] === undefined) { - return true; - } - } -runTestCase(testcase); + +assert.sameValue(s["foo"], undefined, 's["foo"]'); diff --git a/test/built-ins/String/15.5.5.5.2-3-1.js b/test/built-ins/String/15.5.5.5.2-3-1.js index 0329088abb..b6d265f38f 100644 --- a/test/built-ins/String/15.5.5.5.2-3-1.js +++ b/test/built-ins/String/15.5.5.5.2-3-1.js @@ -9,14 +9,9 @@ es5id: 15.5.5.5.2-3-1 description: > String object indexing returns undefined for missing data properties -includes: [runTestCase.js] ---*/ -function testcase() { var s = new String("hello world"); - if (s["foo"] === undefined) { - return true; - } - } -runTestCase(testcase); + +assert.sameValue(s["foo"], undefined, 's["foo"]'); diff --git a/test/built-ins/String/15.5.5.5.2-3-2.js b/test/built-ins/String/15.5.5.5.2-3-2.js index 6448d6bbc6..91e1b7609a 100644 --- a/test/built-ins/String/15.5.5.5.2-3-2.js +++ b/test/built-ins/String/15.5.5.5.2-3-2.js @@ -7,14 +7,9 @@ info: > notation to look up non numeric property names. es5id: 15.5.5.5.2-3-2 description: String value indexing returns undefined for missing data properties -includes: [runTestCase.js] ---*/ -function testcase() { var s = String("hello world"); - if (s["foo"] === undefined) { - return true; - } - } -runTestCase(testcase); + +assert.sameValue(s["foo"], undefined, 's["foo"]'); diff --git a/test/built-ins/String/15.5.5.5.2-3-3.js b/test/built-ins/String/15.5.5.5.2-3-3.js index 1a3278dd75..73df524aee 100644 --- a/test/built-ins/String/15.5.5.5.2-3-3.js +++ b/test/built-ins/String/15.5.5.5.2-3-3.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-3-3 description: > String object indexing returns undefined if the numeric index (NaN) is not an array index -includes: [runTestCase.js] ---*/ -function testcase() { var s = new String("hello world"); - if (s[NaN] === undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[NaN], undefined, 's[NaN]'); diff --git a/test/built-ins/String/15.5.5.5.2-3-4.js b/test/built-ins/String/15.5.5.5.2-3-4.js index 85feb226c1..3f1a038b18 100644 --- a/test/built-ins/String/15.5.5.5.2-3-4.js +++ b/test/built-ins/String/15.5.5.5.2-3-4.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-3-4 description: > String object indexing returns undefined if the numeric index (Infinity) is not an array index -includes: [runTestCase.js] ---*/ -function testcase() { var s = new String("hello world"); - if (s[Infinity] === undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[Infinity], undefined, 's[Infinity]'); diff --git a/test/built-ins/String/15.5.5.5.2-3-5.js b/test/built-ins/String/15.5.5.5.2-3-5.js index 5ae4f23c58..a58b645b2d 100644 --- a/test/built-ins/String/15.5.5.5.2-3-5.js +++ b/test/built-ins/String/15.5.5.5.2-3-5.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-3-5 description: > String object indexing returns undefined if the numeric index ( 2^32-1) is not an array index -includes: [runTestCase.js] ---*/ -function testcase() { var s = new String("hello world"); - if (s[Math.pow(2, 32)-1]===undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[Math.pow(2, 32)-1], undefined, 's[Math.pow(2, 32)-1]'); diff --git a/test/built-ins/String/15.5.5.5.2-3-6.js b/test/built-ins/String/15.5.5.5.2-3-6.js index 05d266aa98..a285440358 100644 --- a/test/built-ins/String/15.5.5.5.2-3-6.js +++ b/test/built-ins/String/15.5.5.5.2-3-6.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-3-6 description: > String value indexing returns undefined if the numeric index (NaN) is not an array index -includes: [runTestCase.js] ---*/ -function testcase() { var s = String("hello world"); - if (s[NaN] === undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[NaN], undefined, 's[NaN]'); diff --git a/test/built-ins/String/15.5.5.5.2-3-7.js b/test/built-ins/String/15.5.5.5.2-3-7.js index 4423b89ce0..ff60fbccb0 100644 --- a/test/built-ins/String/15.5.5.5.2-3-7.js +++ b/test/built-ins/String/15.5.5.5.2-3-7.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-3-7 description: > String value indexing returns undefined if the numeric index (Infinity) is not an array index -includes: [runTestCase.js] ---*/ -function testcase() { var s = String("hello world"); - if (s[Infinity] === undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[Infinity], undefined, 's[Infinity]'); diff --git a/test/built-ins/String/15.5.5.5.2-3-8.js b/test/built-ins/String/15.5.5.5.2-3-8.js index a768680780..e7eb2d0851 100644 --- a/test/built-ins/String/15.5.5.5.2-3-8.js +++ b/test/built-ins/String/15.5.5.5.2-3-8.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-3-8 description: > String value indexing returns undefined if the numeric index ( >= 2^32-1) is not an array index -includes: [runTestCase.js] ---*/ -function testcase() { var s = String("hello world"); - if (s[Math.pow(2, 32)-1]===undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[Math.pow(2, 32)-1], undefined, 's[Math.pow(2, 32)-1]'); diff --git a/test/built-ins/String/15.5.5.5.2-7-1.js b/test/built-ins/String/15.5.5.5.2-7-1.js index b43a7fcd9a..2b4f2493d6 100644 --- a/test/built-ins/String/15.5.5.5.2-7-1.js +++ b/test/built-ins/String/15.5.5.5.2-7-1.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-7-1 description: > String object indexing returns undefined if the numeric index is less than 0 -includes: [runTestCase.js] ---*/ -function testcase() { var s = new String("hello world"); - if (s[-1] === undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[-1], undefined, 's[-1]'); diff --git a/test/built-ins/String/15.5.5.5.2-7-2.js b/test/built-ins/String/15.5.5.5.2-7-2.js index df78c9415d..1bf9c632a9 100644 --- a/test/built-ins/String/15.5.5.5.2-7-2.js +++ b/test/built-ins/String/15.5.5.5.2-7-2.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-7-2 description: > String value indexing returns undefined if the numeric index is less than 0 -includes: [runTestCase.js] ---*/ -function testcase() { var s = String("hello world"); - if (s[-1] === undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[-1], undefined, 's[-1]'); diff --git a/test/built-ins/String/15.5.5.5.2-7-3.js b/test/built-ins/String/15.5.5.5.2-7-3.js index eb03d28d14..66d60ac03b 100644 --- a/test/built-ins/String/15.5.5.5.2-7-3.js +++ b/test/built-ins/String/15.5.5.5.2-7-3.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-7-3 description: > String object indexing returns undefined if the numeric index is greater than the string length -includes: [runTestCase.js] ---*/ -function testcase() { var s = new String("hello world"); - if (s[11] === undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[11], undefined, 's[11]'); diff --git a/test/built-ins/String/15.5.5.5.2-7-4.js b/test/built-ins/String/15.5.5.5.2-7-4.js index b13a09df56..1d06e8d9d4 100644 --- a/test/built-ins/String/15.5.5.5.2-7-4.js +++ b/test/built-ins/String/15.5.5.5.2-7-4.js @@ -9,14 +9,8 @@ es5id: 15.5.5.5.2-7-4 description: > String value indexing returns undefined if the numeric index is greater than the string length -includes: [runTestCase.js] ---*/ -function testcase() { var s = String("hello world"); - if (s[11] === undefined) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(s[11], undefined, 's[11]'); diff --git a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Fail.js b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Fail.js index 5b9b365cd2..6a9ee85854 100644 --- a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Fail.js +++ b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Fail.js @@ -4,13 +4,7 @@ /*--- author: Ryan Lewis description: endsWith should return false when called on 'word' and passed 'r'. -includes: [runTestCase.js] features: [String#endsWith] ---*/ -function testcase() { - if('word'.endsWith('r') === false) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.endsWith('r'), false, '"word".endsWith("r")'); diff --git a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Fail_2.js b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Fail_2.js index 19954e1cfa..0b34a7b410 100644 --- a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Fail_2.js +++ b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Fail_2.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > endsWith should return false when called on 'word' and passed 'd', with an endPosition of 3. -includes: [runTestCase.js] features: [String#endsWith] ---*/ -function testcase() { - if('word'.endsWith('d', 3) === false) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.endsWith('d', 3), false, '"word".endsWith("d", 3)'); diff --git a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success.js b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success.js index b3655ff81d..854bc56eed 100644 --- a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success.js +++ b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > endsWith should return true when called on 'word' and passed 'd' and with no endPosition (defaults to 4). -includes: [runTestCase.js] features: [String#endsWith] ---*/ -function testcase() { - if('word'.endsWith('d') === true) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.endsWith('d'), true, '"word".endsWith("d")'); diff --git a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_2.js b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_2.js index 1e5f5b55e9..23aba85a2f 100644 --- a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_2.js +++ b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_2.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > endsWith should return true when called on 'word' and passed 'd' and with an endPosition of 4. -includes: [runTestCase.js] features: [String#endsWith] ---*/ -function testcase() { - if('word'.endsWith('d', 4) === true) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.endsWith('d', 4), true, '"word".endsWith("d", 4)'); diff --git a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_3.js b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_3.js index 13613026c8..0b8ceae787 100644 --- a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_3.js +++ b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_3.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > endsWith should return true when called on 'word' and passed 'd' and with an endPosition of 25. -includes: [runTestCase.js] features: [String#endsWith] ---*/ -function testcase() { - if('word'.endsWith('d', 25) === true) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.endsWith('d', 25), true, '"word".endsWith("d", 25)'); diff --git a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_4.js b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_4.js index 47147e79ba..5318ce43fd 100644 --- a/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_4.js +++ b/test/built-ins/String/prototype/endsWith/String.prototype.endsWith_Success_4.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > endsWith should return true when called on 'word' and passed 'r', with an endPosition of 3. -includes: [runTestCase.js] features: [String#endsWith] ---*/ -function testcase() { - if('word'.endsWith('r', 3) === true) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.endsWith('r', 3), true, '"word".endsWith("r", 3)'); diff --git a/test/built-ins/String/prototype/includes/String.prototype.includes_FailBadLocation.js b/test/built-ins/String/prototype/includes/String.prototype.includes_FailBadLocation.js index 0606dd1f08..b98ebe9f55 100644 --- a/test/built-ins/String/prototype/includes/String.prototype.includes_FailBadLocation.js +++ b/test/built-ins/String/prototype/includes/String.prototype.includes_FailBadLocation.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > String should return false if a location is passed that is greather than the length of the string. -includes: [runTestCase.js] features: [String#includes] ---*/ -function testcase() { - if('word'.includes('w', 5) === false) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.includes('w', 5), false, '"word".includes("w", 5)'); diff --git a/test/built-ins/String/prototype/includes/String.prototype.includes_FailLocation.js b/test/built-ins/String/prototype/includes/String.prototype.includes_FailLocation.js index dbd28ae96b..c787bb81aa 100644 --- a/test/built-ins/String/prototype/includes/String.prototype.includes_FailLocation.js +++ b/test/built-ins/String/prototype/includes/String.prototype.includes_FailLocation.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > String should return false if a letter is not found in the word starting from the passed location. -includes: [runTestCase.js] features: [String#includes] ---*/ -function testcase() { - if('word'.includes('o', 3) === false) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.includes('o', 3), false, '"word".includes("o", 3)'); diff --git a/test/built-ins/String/prototype/includes/String.prototype.includes_FailMissingLetter.js b/test/built-ins/String/prototype/includes/String.prototype.includes_FailMissingLetter.js index 823971eada..5e468b27f6 100644 --- a/test/built-ins/String/prototype/includes/String.prototype.includes_FailMissingLetter.js +++ b/test/built-ins/String/prototype/includes/String.prototype.includes_FailMissingLetter.js @@ -4,13 +4,7 @@ /*--- author: Ryan Lewis description: String should return false if a letter is not found in the word. -includes: [runTestCase.js] features: [String#includes] ---*/ -function testcase() { - if('word'.includes('a', 0) === false) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.includes('a', 0), false, '"word".includes("a", 0)'); diff --git a/test/built-ins/String/prototype/includes/String.prototype.includes_Success.js b/test/built-ins/String/prototype/includes/String.prototype.includes_Success.js index 2f2635081a..cf71285b57 100644 --- a/test/built-ins/String/prototype/includes/String.prototype.includes_Success.js +++ b/test/built-ins/String/prototype/includes/String.prototype.includes_Success.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > String should return true when called on 'word' and passed 'w' and the location 0. -includes: [runTestCase.js] features: [String#includes] ---*/ -function testcase() { - if('word'.includes('w', 0) === true) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.includes('w', 0), true, '"word".includes("w", 0)'); diff --git a/test/built-ins/String/prototype/includes/String.prototype.includes_SuccessNoLocation.js b/test/built-ins/String/prototype/includes/String.prototype.includes_SuccessNoLocation.js index 76561aef32..3128b0100f 100644 --- a/test/built-ins/String/prototype/includes/String.prototype.includes_SuccessNoLocation.js +++ b/test/built-ins/String/prototype/includes/String.prototype.includes_SuccessNoLocation.js @@ -6,13 +6,7 @@ author: Ryan Lewis description: > String should return true when called on 'word' and passed 'w' and with no location (defaults to 0). -includes: [runTestCase.js] features: [String#includes] ---*/ -function testcase() { - if('word'.includes('w') === true) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.includes('w'), true, '"word".includes("w")'); diff --git a/test/built-ins/String/prototype/includes/String.prototype.includes_lengthProp.js b/test/built-ins/String/prototype/includes/String.prototype.includes_lengthProp.js index 1f15731440..999c8fc88b 100644 --- a/test/built-ins/String/prototype/includes/String.prototype.includes_lengthProp.js +++ b/test/built-ins/String/prototype/includes/String.prototype.includes_lengthProp.js @@ -4,13 +4,7 @@ /*--- author: Ryan Lewis description: String should have the property length with size of 1. -includes: [runTestCase.js] features: [String#includes] ---*/ -function testcase() { - if('word'.includes.length === 1) { - return true; - } - } -runTestCase(testcase); +assert.sameValue('word'.includes.length, 1, '"word".includes.length'); diff --git a/test/built-ins/String/prototype/replace/15.5.4.11-1.js b/test/built-ins/String/prototype/replace/15.5.4.11-1.js index 4b736662f4..7d337df78f 100644 --- a/test/built-ins/String/prototype/replace/15.5.4.11-1.js +++ b/test/built-ins/String/prototype/replace/15.5.4.11-1.js @@ -7,12 +7,9 @@ description: > 'this' object used by the replaceValue function of a String.prototype.replace invocation flags: [noStrict] -includes: - - runTestCase.js - - fnGlobalObject.js +includes: [fnGlobalObject.js] ---*/ -function testcase() { var retVal = 'x'.replace(/x/, function() { if (this===fnGlobalObject()) { @@ -21,6 +18,5 @@ function testcase() { return 'z'; } }); - return retVal==='y'; -} -runTestCase(testcase); + +assert.sameValue(retVal, 'y', 'retVal'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-0-1.js b/test/built-ins/String/prototype/trim/15.5.4.20-0-1.js index 3679dbb4e2..429a17b072 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-0-1.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-0-1.js @@ -4,13 +4,8 @@ /*--- es5id: 15.5.4.20-0-1 description: String.prototype.trim must exist as a function -includes: [runTestCase.js] ---*/ -function testcase() { var f = String.prototype.trim; - if (typeof(f) === "function") { - return true; - } - } -runTestCase(testcase); + +assert.sameValue(typeof(f), "function", 'typeof(f)'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-0-2.js b/test/built-ins/String/prototype/trim/15.5.4.20-0-2.js index 35ee4c7226..61b702e346 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-0-2.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-0-2.js @@ -4,12 +4,6 @@ /*--- es5id: 15.5.4.20-0-2 description: String.prototype.trim must exist as a function taking 0 parameters -includes: [runTestCase.js] ---*/ -function testcase() { - if (String.prototype.trim.length === 0) { - return true; - } - } -runTestCase(testcase); +assert.sameValue(String.prototype.trim.length, 0, 'String.prototype.trim.length'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-1-8.js b/test/built-ins/String/prototype/trim/15.5.4.20-1-8.js index dc48907384..3b93eb1737 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-1-8.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-1-8.js @@ -6,11 +6,9 @@ es5id: 15.5.4.20-1-8 description: > String.prototype.trim works for a primitive string (value is ' abc') -includes: [runTestCase.js] ---*/ -function testcase() { var strObj = String(" abc"); - return "abc" === strObj.trim() && strObj.toString() === " abc"; - } -runTestCase(testcase); + +assert.sameValue(strObj.trim(), "abc", 'strObj.trim()'); +assert.sameValue(strObj.toString(), " abc", 'strObj.toString()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-1-9.js b/test/built-ins/String/prototype/trim/15.5.4.20-1-9.js index 176e584610..cd09927dd8 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-1-9.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-1-9.js @@ -6,11 +6,8 @@ es5id: 15.5.4.20-1-9 description: > String.prototype.trim works for a String object which value is undefined -includes: [runTestCase.js] ---*/ -function testcase() { var strObj = new String(undefined); - return strObj.trim() === "undefined"; - } -runTestCase(testcase); + +assert.sameValue(strObj.trim(), "undefined", 'strObj.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-38.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-38.js index 40f3230e98..163254129a 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-38.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-38.js @@ -6,16 +6,12 @@ es5id: 15.5.4.20-2-38 description: > String.prototype.trim - 'this' is an object which has an own toString method -includes: [runTestCase.js] ---*/ -function testcase() { var obj = { toString: function () { return "abc"; } }; - return (String.prototype.trim.call(obj) === "abc"); - } -runTestCase(testcase); +assert.sameValue(String.prototype.trim.call(obj), "abc", 'String.prototype.trim.call(obj)'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-39.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-39.js index 23442c8caa..2536716ded 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-39.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-39.js @@ -6,16 +6,12 @@ es5id: 15.5.4.20-2-39 description: > String.prototype.trim - 'this' is an object which has an own valueOf method -includes: [runTestCase.js] ---*/ -function testcase() { var obj = { valueOf: function () { return "abc"; } }; - return (String.prototype.trim.call(obj) === "[object Object]"); - } -runTestCase(testcase); +assert.sameValue(String.prototype.trim.call(obj), "[object Object]", 'String.prototype.trim.call(obj)'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-40.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-40.js index e4ba7845e2..4edb83c727 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-40.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-40.js @@ -7,10 +7,8 @@ description: > String.prototype.trim - 'this' is an object that has an own toString method that returns an object and valueOf method that returns a primitive value -includes: [runTestCase.js] ---*/ -function testcase() { var toStringAccessed = false; var valueOfAccessed = false; var obj = { @@ -23,6 +21,7 @@ function testcase() { return "abc"; } }; - return (String.prototype.trim.call(obj) === "abc") && valueOfAccessed && toStringAccessed; - } -runTestCase(testcase); + +assert.sameValue(String.prototype.trim.call(obj), "abc", 'String.prototype.trim.call(obj)'); +assert(valueOfAccessed, 'valueOfAccessed !== true'); +assert(toStringAccessed, 'toStringAccessed !== true'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-41.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-41.js index 98d1320055..a9233a47d1 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-41.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-41.js @@ -6,10 +6,8 @@ es5id: 15.5.4.20-2-41 description: > String.prototype.trim - 'this' is an object which has an own toString and valueOf method. -includes: [runTestCase.js] ---*/ -function testcase() { var toStringAccessed = false; var valueOfAccessed = false; var obj = { @@ -22,6 +20,7 @@ function testcase() { return "cef"; } }; - return (String.prototype.trim.call(obj) === "abc") && !valueOfAccessed && toStringAccessed; - } -runTestCase(testcase); + +assert.sameValue(String.prototype.trim.call(obj), "abc", 'String.prototype.trim.call(obj)'); +assert.sameValue(valueOfAccessed, false, 'valueOfAccessed'); +assert(toStringAccessed, 'toStringAccessed !== true'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-43.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-43.js index 238944ac27..1c9446bdc0 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-43.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-43.js @@ -7,11 +7,8 @@ description: > String.prototype.trim - 'this' is an object with an own valueOf and inherited toString methods with hint string, verify inherited toString method will be called first -includes: [runTestCase.js] ---*/ -function testcase() { - var toStringAccessed = false; var valueOfAccessed = false; @@ -30,6 +27,7 @@ function testcase() { valueOfAccessed = true; return "efg"; }; - return (String.prototype.trim.call(child) === "abc") && toStringAccessed && !valueOfAccessed; - } -runTestCase(testcase); + +assert.sameValue(String.prototype.trim.call(child), "abc", 'String.prototype.trim.call(child)'); +assert(toStringAccessed, 'toStringAccessed !== true'); +assert.sameValue(valueOfAccessed, false, 'valueOfAccessed'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-44.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-44.js index a4aa431f8d..3dbead7888 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-44.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-44.js @@ -6,11 +6,8 @@ es5id: 15.5.4.20-2-44 description: > String.prototype.trim - 'this' is a string that contains east Asian characters (value is 'SD咕噜') -includes: [runTestCase.js] ---*/ -function testcase() { var str = "SD咕噜"; - return str.trim() === str; - } -runTestCase(testcase); + +assert.sameValue(str.trim(), str, 'str.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-45.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-45.js index 1ac68b4ce8..c8c99d70a5 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-45.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-45.js @@ -6,12 +6,9 @@ es5id: 15.5.4.20-2-45 description: > String.prototype.trim - 'this' is a string that contains white space, character, number, object and null characters -includes: [runTestCase.js] ---*/ -function testcase() { var str = "abc" + " " + 123 + " " + {} + " " + "\u0000"; var str1 = " " + str + " "; - return str1.trim() === str; - } -runTestCase(testcase); + +assert.sameValue(str1.trim(), str, 'str1.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-46.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-46.js index ed896250a1..f68088fa36 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-46.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-46.js @@ -6,11 +6,8 @@ es5id: 15.5.4.20-2-46 description: > String.prototype.trim - 'this' is a Function Object that converts to a string -includes: [runTestCase.js] ---*/ -function testcase() { var funObj = function () { return arguments; }; - return typeof(String.prototype.trim.call(funObj)) === "string"; - } -runTestCase(testcase); + +assert.sameValue(typeof(String.prototype.trim.call(funObj)), "string", 'typeof(String.prototype.trim.call(funObj))'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-49.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-49.js index bc4ad97fbc..7eb3a04b37 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-49.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-49.js @@ -6,11 +6,8 @@ es5id: 15.5.4.20-2-49 description: > String.prototype.trim - 'this' is a RegExp Object that converts to a string -includes: [runTestCase.js] ---*/ -function testcase() { var regObj = new RegExp(/test/); - return String.prototype.trim.call(regObj) === "/test/"; - } -runTestCase(testcase); + +assert.sameValue(String.prototype.trim.call(regObj), "/test/", 'String.prototype.trim.call(regObj)'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-50.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-50.js index da4c2d4dfd..7dff7b940f 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-50.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-50.js @@ -6,11 +6,8 @@ es5id: 15.5.4.20-2-50 description: > String.prototype.trim - 'this' is a Error Object that converts to a string -includes: [runTestCase.js] ---*/ -function testcase() { var errObj = new Error("test"); - return String.prototype.trim.call(errObj) === "Error: test"; - } -runTestCase(testcase); + +assert.sameValue(String.prototype.trim.call(errObj), "Error: test", 'String.prototype.trim.call(errObj)'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-2-51.js b/test/built-ins/String/prototype/trim/15.5.4.20-2-51.js index 1f069f0ada..d47c31beb8 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-2-51.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-2-51.js @@ -6,11 +6,8 @@ es5id: 15.5.4.20-2-51 description: > String.prototype.trim - 'this' is a Arguments Object that converts to a string -includes: [runTestCase.js] ---*/ -function testcase() { var argObj = function () { return arguments; } (1, 2, true); - return String.prototype.trim.call(argObj) === "[object Arguments]"; - } -runTestCase(testcase); + +assert.sameValue(String.prototype.trim.call(argObj), "[object Arguments]", 'String.prototype.trim.call(argObj)'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-3-1.js b/test/built-ins/String/prototype/trim/15.5.4.20-3-1.js index 66029872e5..0d7794575a 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-3-1.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-3-1.js @@ -4,12 +4,8 @@ /*--- es5id: 15.5.4.20-3-1 description: String.prototype.trim - 'S' is a string with all LineTerminator -includes: [runTestCase.js] ---*/ -function testcase() { - var lineTerminatorsStr = "\u000A\u000D\u2028\u2029"; - return (lineTerminatorsStr.trim() === ""); - } -runTestCase(testcase); + +assert.sameValue(lineTerminatorsStr.trim(), "", 'lineTerminatorsStr.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-3-2.js b/test/built-ins/String/prototype/trim/15.5.4.20-3-2.js index 8b51fb737c..6be919fc02 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-3-2.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-3-2.js @@ -4,12 +4,8 @@ /*--- es5id: 15.5.4.20-3-2 description: String.prototype.trim - 'S' is a string with all WhiteSpace -includes: [runTestCase.js] ---*/ -function testcase() { - var whiteSpacesStr = "\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF"; - return (whiteSpacesStr.trim() === ""); - } -runTestCase(testcase); + +assert.sameValue(whiteSpacesStr.trim(), "", 'whiteSpacesStr.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-3-3.js b/test/built-ins/String/prototype/trim/15.5.4.20-3-3.js index a9f690d07b..94f9121bcb 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-3-3.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-3-3.js @@ -6,14 +6,10 @@ es5id: 15.5.4.20-3-3 description: > String.prototype.trim - 'S' is a string with all union of WhiteSpace and LineTerminator -includes: [runTestCase.js] ---*/ -function testcase() { var lineTerminatorsStr = "\u000A\u000D\u2028\u2029"; var whiteSpacesStr = "\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF"; var str = whiteSpacesStr + lineTerminatorsStr; - return (str.trim() === ""); - } -runTestCase(testcase); +assert.sameValue(str.trim(), "", 'str.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-3-4.js b/test/built-ins/String/prototype/trim/15.5.4.20-3-4.js index 453c1a4513..a00b8ee11d 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-3-4.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-3-4.js @@ -6,14 +6,10 @@ es5id: 15.5.4.20-3-4 description: > String.prototype.trim - 'S' is a string start with union of all LineTerminator and all WhiteSpace -includes: [runTestCase.js] ---*/ -function testcase() { var lineTerminatorsStr = "\u000A\u000D\u2028\u2029"; var whiteSpacesStr = "\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF"; var str = whiteSpacesStr + lineTerminatorsStr + "abc"; - return (str.trim() === "abc"); - } -runTestCase(testcase); +assert.sameValue(str.trim(), "abc", 'str.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-3-5.js b/test/built-ins/String/prototype/trim/15.5.4.20-3-5.js index e8263207b1..c13159165a 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-3-5.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-3-5.js @@ -6,14 +6,10 @@ es5id: 15.5.4.20-3-5 description: > String.prototype.trim - 'S' is a string end with union of all LineTerminator and all WhiteSpace -includes: [runTestCase.js] ---*/ -function testcase() { var lineTerminatorsStr = "\u000A\u000D\u2028\u2029"; var whiteSpacesStr = "\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF"; var str = "abc" + whiteSpacesStr + lineTerminatorsStr ; - return (str.trim() === "abc"); - } -runTestCase(testcase); +assert.sameValue(str.trim(), "abc", 'str.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-3-6.js b/test/built-ins/String/prototype/trim/15.5.4.20-3-6.js index 145238d45b..875d3357bb 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-3-6.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-3-6.js @@ -7,14 +7,10 @@ description: > String.prototype.trim - 'S' is a string start with union of all LineTerminator and all WhiteSpace and end with union of all LineTerminator and all WhiteSpace -includes: [runTestCase.js] ---*/ -function testcase() { var lineTerminatorsStr = "\u000A\u000D\u2028\u2029"; var whiteSpacesStr = "\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF"; var str = whiteSpacesStr + lineTerminatorsStr + "abc" + whiteSpacesStr + lineTerminatorsStr; - return (str.trim() === "abc"); - } -runTestCase(testcase); +assert.sameValue(str.trim(), "abc", 'str.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-3-7.js b/test/built-ins/String/prototype/trim/15.5.4.20-3-7.js index f8b7a4f960..65b0439f22 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-3-7.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-3-7.js @@ -6,14 +6,10 @@ es5id: 15.5.4.20-3-7 description: > String.prototype.trim - 'S' is a string that union of LineTerminator and WhiteSpace in the middle -includes: [runTestCase.js] ---*/ -function testcase() { var lineTerminatorsStr = "\u000A\u000D\u2028\u2029"; var whiteSpacesStr = "\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF"; var str = "ab" + whiteSpacesStr + lineTerminatorsStr + "cd"; - return (str.trim() === str); - } -runTestCase(testcase); +assert.sameValue(str.trim(), str, 'str.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-1.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-1.js index 8064c5780b..9abc0fdfad 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-1.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-1.js @@ -6,16 +6,11 @@ es5id: 15.5.4.20-4-1 description: > String.prototype.trim handles multiline string with whitepace and lineterminators -includes: [runTestCase.js] ---*/ -function testcase() { var s = "\u0009a b\ c \u0009" - if (s.trim() === "a bc") { - return true; - } - } -runTestCase(testcase); + +assert.sameValue(s.trim(), "a bc", 's.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-11.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-11.js index e8f88f47e4..f7e0b26447 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-11.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-11.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-11 description: > String.prototype.trim handles whitepace and lineterminators (abc\u0009) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u0009".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u0009".trim(), "abc", '"abc\u0009".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-12.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-12.js index a2f335d8db..3caef65790 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-12.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-12.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-12 description: > String.prototype.trim handles whitepace and lineterminators (abc\u000B) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u000B".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u000B".trim(), "abc", '"abc\u000B".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-13.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-13.js index a578d38fdf..234b364ca4 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-13.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-13.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-13 description: > String.prototype.trim handles whitepace and lineterminators (abc\u000C) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u000C".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u000C".trim(), "abc", '"abc\u000C".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-14.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-14.js index 6056f3f67f..251f1c1ed0 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-14.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-14.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-14 description: > String.prototype.trim handles whitepace and lineterminators (abc\u0020) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u0020".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u0020".trim(), "abc", '"abc\u0020".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-16.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-16.js index 5e4786665d..756aad46c5 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-16.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-16.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-16 description: > String.prototype.trim handles whitepace and lineterminators (abc\u00A0) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u00A0".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u00A0".trim(), "abc", '"abc\u00A0".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-19.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-19.js index ebbfc69d2b..6bffa4d109 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-19.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-19.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-19 description: > String.prototype.trim handles whitepace and lineterminators (\u0009abc\u0009) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u0009abc\u0009".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u0009abc\u0009".trim(), "abc", '"\u0009abc\u0009".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-2.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-2.js index 2072a27bd5..62adbfd550 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-2.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-2.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-2 description: > String.prototype.trim handles whitepace and lineterminators ( \u0009abc \u0009) -includes: [runTestCase.js] ---*/ -function testcase() { - if (" \u0009abc \u0009".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue(" \u0009abc \u0009".trim(), "abc", '" \u0009abc \u0009".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-20.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-20.js index 60b9543b4c..04e8e11cd8 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-20.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-20.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-20 description: > String.prototype.trim handles whitepace and lineterminators (\u000Babc\u000B) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000Babc\u000B".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000Babc\u000B".trim(), "abc", '"\u000Babc\u000B".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-21.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-21.js index e39c4ac26f..033f14ba53 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-21.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-21.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-21 description: > String.prototype.trim handles whitepace and lineterminators (\u000Cabc\u000C) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000Cabc\u000C".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000Cabc\u000C".trim(), "abc", '"\u000Cabc\u000C".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-22.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-22.js index 032ac8beaf..4007e5afdc 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-22.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-22.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-22 description: > String.prototype.trim handles whitepace and lineterminators (\u0020abc\u0020) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u0020abc\u0020".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u0020abc\u0020".trim(), "abc", '"\u0020abc\u0020".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-24.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-24.js index b9ccbe1545..2997d65015 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-24.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-24.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-24 description: > String.prototype.trim handles whitepace and lineterminators (\u00A0abc\u00A0) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u00A0abc\u00A0".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u00A0abc\u00A0".trim(), "abc", '"\u00A0abc\u00A0".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-27.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-27.js index a3648a57ac..0b9d1f0188 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-27.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-27.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-27 description: > String.prototype.trim handles whitepace and lineterminators (\u0009\u0009) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u0009\u0009".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u0009\u0009".trim(), "", '"\u0009\u0009".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-28.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-28.js index 976fd7fb8d..7b2643f17b 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-28.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-28.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-28 description: > String.prototype.trim handles whitepace and lineterminators (\u000B\u000B) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000B\u000B".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000B\u000B".trim(), "", '"\u000B\u000B".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-29.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-29.js index 6cebbd89ea..8f40a82f75 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-29.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-29.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-29 description: > String.prototype.trim handles whitepace and lineterminators (\u000C\u000C) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000C\u000C".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000C\u000C".trim(), "", '"\u000C\u000C".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-3.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-3.js index 93f0eb87cf..b91223a8ba 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-3.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-3.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-3 description: > String.prototype.trim handles whitepace and lineterminators (\u0009abc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u0009abc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u0009abc".trim(), "abc", '"\u0009abc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-30.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-30.js index 3a0cb4de6f..2219e34c72 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-30.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-30.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-30 description: > String.prototype.trim handles whitepace and lineterminators (\u0020\u0020) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u0020\u0020".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u0020\u0020".trim(), "", '"\u0020\u0020".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-32.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-32.js index d7b0d193ea..142ace5439 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-32.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-32.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-32 description: > String.prototype.trim handles whitepace and lineterminators (\u00A0\u00A0) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u00A0\u00A0".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u00A0\u00A0".trim(), "", '"\u00A0\u00A0".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-35.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-35.js index 667c167416..4324a99b18 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-35.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-35.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-35 description: > String.prototype.trim handles whitepace and lineterminators (ab\u0009c) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("ab\u0009c".trim() === "ab\u0009c") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("ab\u0009c".trim(), "ab\u0009c", '"ab\u0009c".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-36.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-36.js index 34723ac462..6aab569a09 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-36.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-36.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-36 description: > String.prototype.trim handles whitepace and lineterminators (ab\u000Bc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("ab\u000Bc".trim() === "ab\u000Bc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("ab\u000Bc".trim(), "ab\u000Bc", '"ab\u000Bc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-37.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-37.js index cb6c7f8e22..9c96555557 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-37.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-37.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-37 description: > String.prototype.trim handles whitepace and lineterminators (ab\u000Cc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("ab\u000Cc".trim() === "ab\u000Cc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("ab\u000Cc".trim(), "ab\u000Cc", '"ab\u000Cc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-38.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-38.js index 9f294c4214..6d8254f070 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-38.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-38.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-38 description: > String.prototype.trim handles whitepace and lineterminators (ab\u0020c) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("ab\u0020c".trim() === "ab\u0020c") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("ab\u0020c".trim(), "ab\u0020c", '"ab\u0020c".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-4.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-4.js index a9a1fdcb66..5fee51f1dc 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-4.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-4.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-4 description: > String.prototype.trim handles whitepace and lineterminators (\u000Babc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000Babc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000Babc".trim(), "abc", '"\u000Babc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-40.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-40.js index 59941b09d5..ca352deebc 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-40.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-40.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-40 description: > String.prototype.trim handles whitepace and lineterminators (ab\u00A0c) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("ab\u00A0c".trim() === "ab\u00A0c") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("ab\u00A0c".trim(), "ab\u00A0c", '"ab\u00A0c".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-41.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-41.js index 53f4ac0a53..acf7f33cfe 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-41.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-41.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-41 description: > String.prototype.trim handles whitepace and lineterminators (ab\u200Bc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("ab\u200Bc".trim() === "ab\u200Bc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("ab\u200Bc".trim(), "ab\u200Bc", '"ab\u200Bc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-42.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-42.js index 31ac2106ab..fe54dd19ca 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-42.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-42.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-42 description: > String.prototype.trim handles whitepace and lineterminators (ab\uFEFFc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("ab\uFEFFc".trim() === "ab\uFEFFc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("ab\uFEFFc".trim(), "ab\uFEFFc", '"ab\uFEFFc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-43.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-43.js index a1253b33ef..d475a888c5 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-43.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-43.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-43 description: > String.prototype.trim handles whitepace and lineterminators (\u000Aabc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000Aabc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000Aabc".trim(), "abc", '"\u000Aabc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-44.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-44.js index 23b9c7cf1f..3a368677a2 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-44.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-44.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-44 description: > String.prototype.trim handles whitepace and lineterminators (\u000Dabc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000Dabc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000Dabc".trim(), "abc", '"\u000Dabc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-45.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-45.js index f92d9df2a9..2a1811a92c 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-45.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-45.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-45 description: > String.prototype.trim handles whitepace and lineterminators (\u2028abc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u2028abc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u2028abc".trim(), "abc", '"\u2028abc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-46.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-46.js index f40ad4c928..20653a56d0 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-46.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-46.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-46 description: > String.prototype.trim handles whitepace and lineterminators (\u2029abc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u2029abc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u2029abc".trim(), "abc", '"\u2029abc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-47.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-47.js index 6dcf7da9dc..3ac00096a8 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-47.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-47.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-47 description: > String.prototype.trim handles whitepace and lineterminators (abc\u000A) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u000A".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u000A".trim(), "abc", '"abc\u000A".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-48.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-48.js index f16dfcf8f5..5e3bb87857 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-48.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-48.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-48 description: > String.prototype.trim handles whitepace and lineterminators (abc\u000D) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u000D".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u000D".trim(), "abc", '"abc\u000D".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-49.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-49.js index 288582b180..aff1fa5af0 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-49.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-49.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-49 description: > String.prototype.trim handles whitepace and lineterminators (abc\u2028) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u2028".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u2028".trim(), "abc", '"abc\u2028".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-5.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-5.js index 9af3935a39..b5473c26db 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-5.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-5.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-5 description: > String.prototype.trim handles whitepace and lineterminators (\u000Cabc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000Cabc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000Cabc".trim(), "abc", '"\u000Cabc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-50.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-50.js index 49f5dcdea5..74280cb918 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-50.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-50.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-50 description: > String.prototype.trim handles whitepace and lineterminators (abc\u2029) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("abc\u2029".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("abc\u2029".trim(), "abc", '"abc\u2029".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-51.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-51.js index daf957ec81..308a62ad23 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-51.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-51.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-51 description: > String.prototype.trim handles whitepace and lineterminators (\u000Aabc\u000A) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000Aabc\u000A".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000Aabc\u000A".trim(), "abc", '"\u000Aabc\u000A".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-52.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-52.js index 4b81cf24c1..846ff7e9d6 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-52.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-52.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-52 description: > String.prototype.trim handles whitepace and lineterminators (\u000Dabc\u000D) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000Dabc\u000D".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000Dabc\u000D".trim(), "abc", '"\u000Dabc\u000D".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-53.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-53.js index ff0a0b258e..97e8949f87 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-53.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-53.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-53 description: > String.prototype.trim handles whitepace and lineterminators (\u2028abc\u2028) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u2028abc\u2028".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u2028abc\u2028".trim(), "abc", '"\u2028abc\u2028".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-54.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-54.js index aa51015f48..3fab5ec6eb 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-54.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-54.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-54 description: > String.prototype.trim handles whitepace and lineterminators (\u2029abc\u2029) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u2029abc\u2029".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u2029abc\u2029".trim(), "abc", '"\u2029abc\u2029".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-55.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-55.js index 6997e3bbbc..ccbe68cbe7 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-55.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-55.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-55 description: > String.prototype.trim handles whitepace and lineterminators (\u000A\u000A) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000A\u000A".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000A\u000A".trim(), "", '"\u000A\u000A".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-56.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-56.js index b0371c1f52..2f648d6928 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-56.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-56.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-56 description: > String.prototype.trim handles whitepace and lineterminators (\u000D\u000D) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u000D\u000D".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u000D\u000D".trim(), "", '"\u000D\u000D".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-57.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-57.js index 10fe688aca..e13d6a0c08 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-57.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-57.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-57 description: > String.prototype.trim handles whitepace and lineterminators (\u2028\u2028) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u2028\u2028".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u2028\u2028".trim(), "", '"\u2028\u2028".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-58.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-58.js index f34a8b6109..b06974f583 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-58.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-58.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-58 description: > String.prototype.trim handles whitepace and lineterminators (\u2029\u2029) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u2029\u2029".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u2029\u2029".trim(), "", '"\u2029\u2029".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-59.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-59.js index b041e0ab38..13a98eb6c5 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-59.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-59.js @@ -6,14 +6,9 @@ es5id: 15.5.4.20-4-59 description: > String.prototype.trim handles whitepace and lineterminators (\u2029abc as a multiline string) -includes: [runTestCase.js] ---*/ -function testcase() { var s = "\u2029\ abc"; - if (s.trim() === "abc") { - return true; - } - } -runTestCase(testcase); + +assert.sameValue(s.trim(), "abc", 's.trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-6.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-6.js index 410c064552..e37c01bbaf 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-6.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-6.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-6 description: > String.prototype.trim handles whitepace and lineterminators (\u0020abc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u0020abc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u0020abc".trim(), "abc", '"\u0020abc".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-60.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-60.js index 95af050af0..6cd066500d 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-60.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-60.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-60 description: > String.prototype.trim handles whitepace and lineterminators (string with just blanks) -includes: [runTestCase.js] ---*/ -function testcase() { - if (" ".trim() === "") { - return true; - } - } -runTestCase(testcase); +assert.sameValue(" ".trim(), "", '" ".trim()'); diff --git a/test/built-ins/String/prototype/trim/15.5.4.20-4-8.js b/test/built-ins/String/prototype/trim/15.5.4.20-4-8.js index 6b156d9952..0304afed30 100644 --- a/test/built-ins/String/prototype/trim/15.5.4.20-4-8.js +++ b/test/built-ins/String/prototype/trim/15.5.4.20-4-8.js @@ -6,12 +6,6 @@ es5id: 15.5.4.20-4-8 description: > String.prototype.trim handles whitepace and lineterminators (\u00A0abc) -includes: [runTestCase.js] ---*/ -function testcase() { - if ("\u00A0abc".trim() === "abc") { - return true; - } - } -runTestCase(testcase); +assert.sameValue("\u00A0abc".trim(), "abc", '"\u00A0abc".trim()');