From f75d78f56a907d4b3641dacd7461c2827c31ec86 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Sun, 24 Oct 2021 14:33:56 +0200 Subject: LibJS: Include executable name in bytecode dumps --- Userland/Libraries/LibTest/JavaScriptTestRunner.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'Userland/Libraries/LibTest') 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()); -- cgit v1.2.3