Skip to content

Commit

Permalink
Tests: Remove 4chan catalog JSON from tree
Browse files Browse the repository at this point in the history
According to kling, it was "an early stress test for the JSON decoder"
and can be removed now.
  • Loading branch information
sin-ack authored and awesomekling committed Apr 25, 2021
1 parent 5b69e8d commit bb09642
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 25 deletions.
1 change: 0 additions & 1 deletion AK/Tests/4chan_catalog.json

This file was deleted.

1 change: 0 additions & 1 deletion AK/Tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -65,5 +65,4 @@ foreach(source ${AK_TEST_SOURCES})
endforeach()

get_filename_component(TEST_FRM_RESOLVED ./test.frm REALPATH)
install(FILES ./4chan_catalog.json DESTINATION usr/Tests/AK)
install(FILES ${TEST_FRM_RESOLVED} DESTINATION usr/Tests/AK)
23 changes: 0 additions & 23 deletions AK/Tests/TestJSON.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,29 +46,6 @@ TEST_CASE(load_form)
});
}

BENCHMARK_CASE(load_4chan_catalog)
{
FILE* fp = fopen("4chan_catalog.json", "r");
VERIFY(fp);

StringBuilder builder;
for (;;) {
char buffer[1024];
if (!fgets(buffer, sizeof(buffer), fp))
break;
builder.append(buffer);
}

fclose(fp);

auto json_string = builder.to_string();

for (int i = 0; i < 10; ++i) {
JsonValue form_json = JsonValue::from_string(json_string).value();
EXPECT(form_json.is_array());
}
}

TEST_CASE(json_empty_string)
{
auto json = JsonValue::from_string("\"\"").value();
Expand Down

0 comments on commit bb09642

Please sign in to comment.