summaryrefslogtreecommitdiffstats
path: root/js/src/tests/non262/Tuple/from/mapfn-throws-exception.js
blob: fd3d78fb981debfc2debdcebc2549b380da83802 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// |reftest| skip-if(!this.hasOwnProperty("Tuple"))
var array = [2, 4, 8, 16, 32, 64, 128];

function mapFnThrows(value, index, obj) {
  throw new RangeError();
}

assertThrowsInstanceOf(function() {
  Tuple.from(array, mapFnThrows);
}, RangeError, 'Tuple.from(array, mapFnThrows) throws');

reportCompare(0, 0);