mirror of
https://github.com/nodejs/node.git
synced 2024-12-01 16:10:02 +01:00
test: fix parallel/test-repl with new v8
Per the ES6 spec, V8 3.31 no longer throws a SyntaxError for scoped function declarations. PR-URL: https://github.com/iojs/io.js/pull/243 Reviewed-By: Domenic Denicola <domenic@domenicdenicola.com> Reviewed-By: Fedor Indutny <fedor@indutny.com> Reviewed-By: Trevor Norris <trev.norris@gmail.com>
This commit is contained in:
parent
58f3a0382b
commit
6e9d1c8684
@ -166,7 +166,7 @@ function error_test() {
|
||||
expect: /^SyntaxError: Delete of an unqualified identifier in strict mode/ },
|
||||
{ client: client_unix, send: '(function() { "use strict"; eval = 17; })()',
|
||||
expect: /^SyntaxError: Unexpected eval or arguments in strict mode/ },
|
||||
{ client: client_unix, send: '(function() { "use strict"; if (true){ function f() { } } })()',
|
||||
{ client: client_unix, send: '(function() { "use strict"; if (true) function f() { } })()',
|
||||
expect: /^SyntaxError: In strict mode code, functions can only be declared at top level or immediately within another function/ },
|
||||
// Named functions can be used:
|
||||
{ client: client_unix, send: 'function blah() { return 1; }',
|
||||
|
Loading…
Reference in New Issue
Block a user