Lines Matching refs:shouldThrow
54 shouldThrow("x = class", "'SyntaxError: Unexpected end of input'");
55 shouldThrow("x = class {", "'SyntaxError: Unexpected end of input'");
56 shouldThrow("x = class { ( }", "'SyntaxError: Unexpected token ('");
59 shouldThrow("x = class { constructor() {} constructor() {} }", "'SyntaxError: A class may only have…
60 shouldThrow("x = class { get constructor() {} }", "'SyntaxError: Class constructor may not be an ac…
61 shouldThrow("x = class { set constructor() {} }", "'SyntaxError: Class constructor may not be an ac…
65 shouldThrow("x = class { constructor() {} static prototype() {} }", "'SyntaxError: Classes may not …
66 shouldThrow("x = class { constructor() {} static get prototype() {} }", "'SyntaxError: Classes may …
67 shouldThrow("x = class { constructor() {} static set prototype() {} }", "'SyntaxError: Classes may …
73 shouldThrow("x = class { constructor() {} set foo() {} }");
74 shouldThrow("x = class { constructor() {} set foo(a, b) {} }");
76 shouldThrow("x = class { constructor() {} get foo(x) {} }");
77 shouldThrow("x = class { constructor() {} get foo({x, y}) {} }");