summaryrefslogtreecommitdiffstats
path: root/js/src/tests/test262/built-ins/String/prototype/includes/String.prototype.includes_FailBadLocation.js
blob: 73876d539218ab3c3b7b8ab5b0f04f323f87dfd8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Copyright (c) 2014 Ryan Lewis. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.

/*---
author: Ryan Lewis
description: >
    String should return false if a location is passed that is
    greather than the length of the string.
features: [String.prototype.includes]
---*/

assert.sameValue('word'.includes('w', 5), false, '"word".includes("w", 5)');

reportCompare(0, 0);