summaryrefslogtreecommitdiff
path: root/test/built-ins/Array/prototype/indexOf/15.4.4.14-5-33.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/built-ins/Array/prototype/indexOf/15.4.4.14-5-33.js')
-rw-r--r--test/built-ins/Array/prototype/indexOf/15.4.4.14-5-33.js15
1 files changed, 5 insertions, 10 deletions
diff --git a/test/built-ins/Array/prototype/indexOf/15.4.4.14-5-33.js b/test/built-ins/Array/prototype/indexOf/15.4.4.14-5-33.js
index 6c46d4995..791bc1b6b 100644
--- a/test/built-ins/Array/prototype/indexOf/15.4.4.14-5-33.js
+++ b/test/built-ins/Array/prototype/indexOf/15.4.4.14-5-33.js
@@ -6,15 +6,10 @@ es5id: 15.4.4.14-5-33
description: >
Array.prototype.indexOf match on the first element, a middle
element and the last element when 'fromIndex' is passed
-includes: [runTestCase.js]
---*/
-function testcase() {
-
- return [0, 1, 2, 3, 4].indexOf(0, 0) === 0 &&
- [0, 1, 2, 3, 4].indexOf(2, 1) === 2 &&
- [0, 1, 2, 3, 4].indexOf(2, 2) === 2 &&
- [0, 1, 2, 3, 4].indexOf(4, 2) === 4 &&
- [0, 1, 2, 3, 4].indexOf(4, 4) === 4;
- }
-runTestCase(testcase);
+assert.sameValue([0, 1, 2, 3, 4].indexOf(0, 0), 0, '[0, 1, 2, 3, 4].indexOf(0, 0)');
+assert.sameValue([0, 1, 2, 3, 4].indexOf(2, 1), 2, '[0, 1, 2, 3, 4].indexOf(2, 1)');
+assert.sameValue([0, 1, 2, 3, 4].indexOf(2, 2), 2, '[0, 1, 2, 3, 4].indexOf(2, 2)');
+assert.sameValue([0, 1, 2, 3, 4].indexOf(4, 2), 4, '[0, 1, 2, 3, 4].indexOf(4, 2)');
+assert.sameValue([0, 1, 2, 3, 4].indexOf(4, 4), 4, '[0, 1, 2, 3, 4].indexOf(4, 4)');