mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 01:35:08 +02:00
LibJS: Sync additional Import Attributes spec changes
Some steps were not updated with tc39/ecma262#3057. This patch syncs the remaining changes.
This commit is contained in:
committed by
Jelle Raaijmakers
parent
f8c4043460
commit
61c36e2865
Notes:
github-actions[bot]
2025-10-22 08:59:25 +00:00
Author: https://github.com/F3n67u Commit: https://github.com/LadybirdBrowser/ladybird/commit/61c36e28654 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6276 Reviewed-by: https://github.com/gmta ✅
@@ -196,6 +196,18 @@ int main(int argc, char** argv)
|
||||
if (!g_vm) {
|
||||
g_vm = JS::VM::create();
|
||||
g_vm->set_dynamic_imports_allowed(true);
|
||||
|
||||
// Configure the test VM to support additional import attributes
|
||||
// This allows tests to use import attributes beyond just "type"
|
||||
Test::JS::g_vm->host_get_supported_import_attributes = []() -> Vector<Utf16String> {
|
||||
return {
|
||||
"type"_utf16,
|
||||
"key"_utf16, // Used in modules/import-with-attributes.mjs test
|
||||
"key1"_utf16, // Used in modules/basic-modules.js
|
||||
"key2"_utf16, // Used in modules/import-with-attributes.mjs test
|
||||
"default"_utf16, // Used in modules/import-with-attributes.mjs test
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
Test::JS::TestRunner test_runner(test_root, common_path, print_times, print_progress, print_json, per_file);
|
||||
|
||||
Reference in New Issue
Block a user