mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-30 13:19:47 +00:00
AK+Everywhere: Store JSON object keys as String
This commit is contained in:
@@ -370,12 +370,12 @@ inline JSFileResult TestRunner::run_file_test(ByteString const& test_path)
|
||||
file_result.logged_messages.append(message.to_string_without_side_effects().to_byte_string());
|
||||
}
|
||||
|
||||
test_json.value().as_object().for_each_member([&](ByteString const& suite_name, JsonValue const& suite_value) {
|
||||
test_json.value().as_object().for_each_member([&](String const& suite_name, JsonValue const& suite_value) {
|
||||
Test::Suite suite { test_path, suite_name };
|
||||
|
||||
VERIFY(suite_value.is_object());
|
||||
|
||||
suite_value.as_object().for_each_member([&](ByteString const& test_name, JsonValue const& test_value) {
|
||||
suite_value.as_object().for_each_member([&](String const& test_name, JsonValue const& test_value) {
|
||||
Test::Case test { test_name, Test::Result::Fail, "", 0 };
|
||||
|
||||
VERIFY(test_value.is_object());
|
||||
@@ -427,10 +427,10 @@ inline JSFileResult TestRunner::run_file_test(ByteString const& test_path)
|
||||
});
|
||||
|
||||
if (top_level_result.is_error()) {
|
||||
Test::Suite suite { test_path, "<top-level>" };
|
||||
Test::Suite suite { test_path, "<top-level>"_string };
|
||||
suite.most_severe_test_result = Result::Crashed;
|
||||
|
||||
Test::Case test_case { "<top-level>", Test::Result::Fail, "", 0 };
|
||||
Test::Case test_case { "<top-level>"_string, Test::Result::Fail, "", 0 };
|
||||
auto error = top_level_result.release_error().release_value().release_value();
|
||||
if (error.is_object()) {
|
||||
StringBuilder detail_builder;
|
||||
|
||||
Reference in New Issue
Block a user