Home
last modified time | relevance | path

Searched refs:assertThrows (Results 1 – 25 of 74) sorted by relevance

123

/external/v8/test/mjsunit/regress/
Dregress-219.js60 assertThrows("/a/ii");
62 assertThrows("/a/gii");
64 assertThrows("/a/igi");
66 assertThrows("/a/iig");
68 assertThrows("/a/gimi");
70 assertThrows("/a/giim");
72 assertThrows("/a/igim");
74 assertThrows(function(){ return RegExp("a", "ii"); })
76 assertThrows(function(){ return RegExp("a", "gii"); })
78 assertThrows(function(){ return RegExp("a", "igi"); })
[all …]
Dregress-87.js36 assertThrows("/x/\\u0067");
37 assertThrows("/x/\\u0069");
38 assertThrows("/x/\\u006d");
40 assertThrows("/x/\\u0067i");
41 assertThrows("/x/\\u0069m");
42 assertThrows("/x/\\u006dg");
44 assertThrows("/x/m\\u0067");
45 assertThrows("/x/g\\u0069");
46 assertThrows("/x/i\\u006d");
48 assertThrows("/x/m\\u0067i");
[all …]
Dregress-1620.js36 assertThrows("var \\u\\u\\u = 42;");
37 assertThrows("var \\u41 = 42;");
38 assertThrows("var \\u123 = 42;");
41 assertThrows("var uuu = 42; var x = \\u\\u\\u");
50 assertThrows("/x/g\\uim", SyntaxError);
51 assertThrows("/x/g\\u2im", SyntaxError);
52 assertThrows("/x/g\\u22im", SyntaxError);
53 assertThrows("/x/g\\u222im", SyntaxError);
54 assertThrows("/x/g\\\\u2222im", SyntaxError);
Dregress-1415.js30 assertThrows(function(){ decodeURIComponent("%ED%A0%80"); }, URIError);
32 assertThrows(function(){ decodeURIComponent("%ED%AF%BF"); }, URIError);
34 assertThrows(function(){ decodeURIComponent("%ED%B0%80"); }, URIError);
36 assertThrows(function(){ decodeURIComponent("%ED%BF%BF"); }, URIError);
40 assertThrows(function(){ decodeURIComponent("%C1%BF"); }, URIError);
42 assertThrows(function(){ decodeURIComponent("%E0%9F%BF"); }, URIError);
Dregress-603.js33 assertThrows(function() {
39 assertThrows(function() {
44 assertThrows(function() {
49 assertThrows(function() {
55 assertThrows(function() {
61 assertThrows(function() {
Dregress-1924.js33 assertThrows("a: break a a", SyntaxError)
34 assertThrows("a: break a 1", SyntaxError)
35 assertThrows("a: break a ''", SyntaxError)
36 assertThrows("a: break a var b", SyntaxError)
37 assertThrows("a: break a {}", SyntaxError)
Dregress-1112051.js30 assertThrows("f.call.apply()");
31 assertThrows("f.call.apply(null)");
32 assertThrows("f.call.apply(null, [], 0)");
33 assertThrows("f.call.apply(null, [1,2,3,4,5,6,7,8,9], 0)");
Dregress-95920.js32 assertThrows(function() {
39 assertThrows(function() {
46 assertThrows(function() {
53 assertThrows(function() {
Dregress-1122.js65 assertThrows("function_with_n_params_and_m_args(35000, 35000)");
66 assertThrows("function_with_n_params_and_m_args(100000, 100000)");
67 assertThrows("function_with_n_params_and_m_args(35000, 30000)");
68 assertThrows("function_with_n_params_and_m_args(30000, 35000)");
Dregress-1365.js43 assertThrows(callGlobalValueOf);
44 assertThrows(callGlobalHasOwnProperty);
50 assertThrows(callGlobalValueOf);
51 assertThrows(callGlobalHasOwnProperty);
/external/v8/test/mjsunit/
Dinvalid-lhs.js32 assertThrows("12 = 12");
33 assertThrows("x++ = 12");
34 assertThrows("eval('var x') = 12");
38 assertThrows("12++");
39 assertThrows("12--");
40 assertThrows("--12");
41 assertThrows("++12");
42 assertThrows("++(eval('12'))");
43 assertThrows("(eval('12'))++");
48 assertThrows("for (12 in [1]) print(12);");
[all …]
Dstrict-mode.js30 assertThrows("'use strict';\n" + code, exception);
31 assertThrows('"use strict";\n' + code, exception);
38 assertThrows("\
59 assertThrows(function() {
71 assertThrows("function foo (x) 'use strict'; {}", SyntaxError);
81 assertThrows('\
136 assertThrows('\
163 assertThrows('\
192 assertThrows("var x = { get foo() { }, get foo() { } };", SyntaxError);
193 assertThrows("var x = { get foo(){}, get 'foo'(){}};", SyntaxError);
[all …]
Dd8-os.js76 assertThrows("os.system('ls', [TEST_DIR + '/dir/bar']);", "dir not there");
89 assertThrows("os.mkdirp(TEST_DIR + '/file1');", "mkdir over file1");
90 assertThrows("os.mkdirp(TEST_DIR + '/file1/foo');", "mkdir over file2");
91 assertThrows("os.mkdirp(TEST_DIR + '/file1/');", "mkdir over file3");
92 assertThrows("os.mkdirp(TEST_DIR + '/file1/foo/');", "mkdir over file4");
96 assertThrows("os.chdir(TEST_DIR + '/dir4');", "chdir dir4 I");
98 assertThrows("os.chdir(TEST_DIR + '/dir4');", "chdir dir4 II");
106 assertThrows("os.chdir(TEST_DIR + '/dir5');", "cd dir5 I");
108 assertThrows("os.chdir(TEST_DIR + '/dir5');", "chdir dir5 II");
132 assertThrows("os.system('sleep', ['2000'], 200);", "sleep 1");
[all …]
Dkeywords-and-reserved_words.js80 assertThrows("var " + word + " = 1;", SyntaxError);
82 assertThrows("typeof (" + word + ");", SyntaxError);
96 assertThrows("function " + word + " () { }", SyntaxError);
97 assertThrows("function foo (" + word + ") {}", SyntaxError);
98 assertThrows("function foo (a, " + word + ") { }", SyntaxError);
99 assertThrows("function foo (" + word + ", a) { }", SyntaxError);
100 assertThrows("function foo (a, " + word + ", b) { }", SyntaxError);
101 assertThrows("var foo = function (" + word + ") { }", SyntaxError);
104 assertThrows("var x = { set foo(" + word + ") { } };", SyntaxError);
Ddelay-syntax-error.js36 assertThrows("if (false) break;");
37 assertThrows("if (false) continue;");
40 assertThrows("return;");
41 assertThrows("break;");
42 assertThrows("continue;");
Darray-length-number-conversion.js49 assertThrows("var y = []; y.length = 'abc';");
50 assertThrows("var y = []; y.length = undefined;");
51 assertThrows("var y = []; y.length = {};");
52 assertThrows("var y = []; y.length = -1;");
53 assertThrows("var y = []; y.length = {valueOf:function() { throw new Error(); }};");
Dif-in-undefined.js33 assertThrows("if ('p' in undefined) { }");
34 assertThrows("if ('p' in null) { }")
35 assertThrows("if ('p' in true) { }");
36 assertThrows("if ('p' in 5) { }");
Darray-join.js57 assertThrows("a.join('')");
58 assertThrows("a.join('*')");
59 assertThrows("a.join('**')");
60 assertThrows("a.join('****')");
61 assertThrows("a.join('********')");
62 assertThrows("a.join('**********')");
Dcall-non-function.js60 assertThrows(WillThrow);
61 assertThrows(WillThrow);
62 assertThrows(WillThrow);
63 assertThrows(WillThrow);
Dgetter-in-prototype.js41 assertThrows(function() { 'use strict'; o.x = 42; });
42 assertThrows(function() { 'use strict'; o[0] = 42; });
65 assertThrows(g_strict);
78 assertThrows(g2_strict);
/external/v8/test/mjsunit/harmony/
Dproxies-function.js280 assertThrows(function(){ f(11) }, "myexn")
281 assertThrows(function(){ ({x: f}).x(11) }, "myexn")
282 assertThrows(function(){ ({x: f})["x"](11) }, "myexn")
283 assertThrows(function(){ Function.prototype.call.call(f, {}, 2) }, "myexn")
284 assertThrows(function(){ Function.prototype.apply.call(f, {}, [1]) }, "myexn")
285 assertThrows(function(){ %Call({}, f) }, "myexn")
286 assertThrows(function(){ %Call({}, 1, 2, f) }, "myexn")
287 assertThrows(function(){ %Apply({}, f, [], 3, 0) }, "myexn")
288 assertThrows(function(){ %Apply({}, f, [3, 4], 0, 1) }, "myexn")
289 assertThrows(function(){ %_CallFunction({}, f) }, "myexn")
[all …]
Dproxies-example-membrane.js249 assertThrows(function() { w.a }, Error);
250 assertThrows(function() { w.r }, Error);
251 assertThrows(function() { w.r = {a: 4} }, Error);
252 assertThrows(function() { o.r.a }, Error);
256 assertThrows(function() { w[1] }, Error);
257 assertThrows(function() { w.c }, Error);
258 assertThrows(function() { wb.bb }, Error);
259 assertThrows(function() { wr.a }, Error);
260 assertThrows(function() { wf(4) }, Error);
261 assertThrows(function() { wfx.a }, Error);
[all …]
Dblock-for.js97 assertThrows("function foo() { 'use strict'; for (let in {}) { } }", SyntaxError);
98 assertThrows("function foo() { 'use strict'; for (let x = 3 in {}) { } }", SyntaxError);
99 assertThrows("function foo() { 'use strict'; for (let x, y in {}) { } }", SyntaxError);
100 assertThrows("function foo() { 'use strict'; for (let x = 3, y in {}) { } }", SyntaxError);
101 assertThrows("function foo() { 'use strict'; for (let x, y = 4 in {}) { } }", SyntaxError);
102 assertThrows("function foo() { 'use strict'; for (let x = 3, y = 4 in {}) { } }", SyntaxError);
Dproxies.js93 assertThrows(function(){ Object.getOwnPropertyDescriptor(p, "a") }, "myexn")
94 assertThrows(function(){ Object.getOwnPropertyDescriptor(p, 77) }, "myexn")
299 assertThrows(function(){ p.a }, "myexn")
300 assertThrows(function(){ p["b"] }, "myexn")
301 assertThrows(function(){ p[3] }, "myexn")
302 assertThrows(function(){ (function(n) { p[n] })("c") }, "myexn")
303 assertThrows(function(){ (function(n) { p[n] })(99) }, "myexn")
306 assertThrows(function(){ o.a }, "myexn")
307 assertThrows(function(){ o["b"] }, "myexn")
308 assertThrows(function(){ o[3] }, "myexn")
[all …]
/external/v8/test/mjsunit/third_party/
Dobject-keys.js34 assertThrows(function () { Object.keys(2) }, TypeError);
35 assertThrows(function () { Object.keys("foo") }, TypeError);
36 assertThrows(function () { Object.keys(null) }, TypeError);
37 assertThrows(function () { Object.keys(undefined) }, TypeError);

123