summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibTest
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2021-10-24 14:33:56 +0200
committerAndreas Kling <kling@serenityos.org>2021-10-24 17:18:06 +0200
commitf75d78f56a907d4b3641dacd7461c2827c31ec86 (patch)
tree9a1eac5271e74081744d8668207a03549ac7a9f1 /Userland/Libraries/LibTest
parentc95dde971b7f0f5071ce778dc20da83cb15a6627 (diff)
downloadserenity-f75d78f56a907d4b3641dacd7461c2827c31ec86.zip
LibJS: Include executable name in bytecode dumps
Diffstat (limited to 'Userland/Libraries/LibTest')
-rw-r--r--Userland/Libraries/LibTest/JavaScriptTestRunner.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/Userland/Libraries/LibTest/JavaScriptTestRunner.h b/Userland/Libraries/LibTest/JavaScriptTestRunner.h
index 436c327d48..231986f847 100644
--- a/Userland/Libraries/LibTest/JavaScriptTestRunner.h
+++ b/Userland/Libraries/LibTest/JavaScriptTestRunner.h
@@ -337,6 +337,7 @@ inline JSFileResult TestRunner::run_file_test(const String& test_path)
if (g_run_bytecode) {
auto executable = JS::Bytecode::Generator::generate(m_test_script->parse_node());
+ executable.name = test_path;
if (JS::Bytecode::g_dump_bytecode)
executable.dump();
JS::Bytecode::Interpreter bytecode_interpreter(interpreter->global_object(), interpreter->realm());
@@ -352,6 +353,7 @@ inline JSFileResult TestRunner::run_file_test(const String& test_path)
return { test_path, file_script.error() };
if (g_run_bytecode) {
auto executable = JS::Bytecode::Generator::generate(file_script.value()->parse_node());
+ executable.name = test_path;
if (JS::Bytecode::g_dump_bytecode)
executable.dump();
JS::Bytecode::Interpreter bytecode_interpreter(interpreter->global_object(), interpreter->realm());