mirror of https://github.com/tc39/test262.git
18 lines
393 B
JavaScript
18 lines
393 B
JavaScript
//-----------------------------------------------------------------------------
|
|
function arrayContains(arr, expected) {
|
|
var found;
|
|
for (var i = 0; i < expected.length; i++) {
|
|
found = false;
|
|
for (var j = 0; j < arr.length; j++) {
|
|
if (expected[i] === arr[j]) {
|
|
found = true;
|
|
break;
|
|
}
|
|
}
|
|
if (!found) {
|
|
return false;
|
|
}
|
|
}
|
|
return true;
|
|
}
|