mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 01:27:42 +00:00
LibTest: Remove uses of TRY_OR_DISCARD() from JavaScriptTestRunner
In one case we can replace it with MUST() and accept the crash (we also VERIFY() that there wasn't an exception); in the other case we don't need to return after a throw completion.
This commit is contained in:
parent
6c9cf4d31a
commit
c4f0f1cc05
1 changed files with 2 additions and 2 deletions
|
@ -336,7 +336,7 @@ inline JSFileResult TestRunner::run_file_test(const String& test_path)
|
|||
if (JS::Bytecode::g_dump_bytecode)
|
||||
executable.dump();
|
||||
JS::Bytecode::Interpreter bytecode_interpreter(interpreter->global_object(), interpreter->realm());
|
||||
TRY_OR_DISCARD(bytecode_interpreter.run(executable));
|
||||
MUST(bytecode_interpreter.run(executable));
|
||||
} else {
|
||||
interpreter->run(interpreter->global_object(), m_test_script->parse_node());
|
||||
}
|
||||
|
@ -352,7 +352,7 @@ inline JSFileResult TestRunner::run_file_test(const String& test_path)
|
|||
if (JS::Bytecode::g_dump_bytecode)
|
||||
executable.dump();
|
||||
JS::Bytecode::Interpreter bytecode_interpreter(interpreter->global_object(), interpreter->realm());
|
||||
TRY_OR_DISCARD(bytecode_interpreter.run(executable));
|
||||
(void)bytecode_interpreter.run(executable);
|
||||
} else {
|
||||
interpreter->run(interpreter->global_object(), file_script.value()->parse_node());
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue