srctree

Robin Linden parent 14bec12d 5d982074
html2/test: Set up all* html5lib tests

  • *the remaining tests require that the JSON test loader has received a
  • bit more love.
inlinesplit
WORKSPACE added: 41, removed: 10, total 31
@@ -139,7 +139,7 @@ local_repository(
# https://github.com/html5lib/html5lib-tests/
http_archive(
name = "html5lib-tests", # MIT
build_file_content = """exports_files(["tokenizer/test1.test"])""",
build_file = "//third_party:html5lib-tests.BUILD",
integrity = "sha256-mUhh8tSAqB9amozHbhgHVKqcDWEQe0dhiWbaUm8bFI0=",
strip_prefix = "html5lib-tests-a9f44960a9fedf265093d22b2aa3c7ca123727b9",
url = "https://github.com/html5lib/html5lib-tests/archive/a9f44960a9fedf265093d22b2aa3c7ca123727b9.tar.gz",
 
html2/BUILD added: 41, removed: 10, total 31
@@ -47,12 +47,12 @@ extra_deps = {
],
)]
 
# TODO(robinlinden): Run all tests.
cc_test(
name = "html5lib_test",
# TODO(robinlinden): Look into the remaining tests.
[cc_test(
name = "html5lib_{}".format(test.rpartition("/")[-1][:-5]),
size = "small",
srcs = ["html5lib_test.cpp"],
args = ["$(location @html5lib-tests//:tokenizer/test1.test)"],
args = ["$(location {})".format(test)],
copts = HASTUR_COPTS + select({
# simdjson leaks a bunch of warnings into our code.
"@platforms//os:windows": [
@@ -61,7 +61,7 @@ cc_test(
],
"//conditions:default": [],
}),
data = ["@html5lib-tests//:tokenizer/test1.test"],
data = [test],
# simdjson seems to blow up qemu when we run our aarch64 crosscompiled
# tests.
tags = ["no-cross"],
@@ -70,7 +70,22 @@ cc_test(
"//etest",
"@simdjson",
],
)
) for test in [
# "@html5lib-tests//:tokenizer/contentModelFlags.test",
# "@html5lib-tests//:tokenizer/domjs.test",
"@html5lib-tests//:tokenizer/entities.test",
# "@html5lib-tests//:tokenizer/escapeFlag.test",
"@html5lib-tests//:tokenizer/namedEntities.test",
"@html5lib-tests//:tokenizer/numericEntities.test",
"@html5lib-tests//:tokenizer/pendingSpecChanges.test",
"@html5lib-tests//:tokenizer/test1.test",
"@html5lib-tests//:tokenizer/test2.test",
"@html5lib-tests//:tokenizer/test3.test",
"@html5lib-tests//:tokenizer/test4.test",
"@html5lib-tests//:tokenizer/unicodeChars.test",
"@html5lib-tests//:tokenizer/unicodeCharsProblematic.test",
# "@html5lib-tests//:tokenizer/xmlViolation.test",
]]
 
[cc_fuzz_test(
name = src[:-4],
 
filename was Deleted added: 41, removed: 10, total 31
@@ -0,0 +1,16 @@
exports_files([
"tokenizer/contentModelFlags.test",
"tokenizer/domjs.test",
"tokenizer/entities.test",
"tokenizer/escapeFlag.test",
"tokenizer/namedEntities.test",
"tokenizer/numericEntities.test",
"tokenizer/pendingSpecChanges.test",
"tokenizer/test1.test",
"tokenizer/test2.test",
"tokenizer/test3.test",
"tokenizer/test4.test",
"tokenizer/unicodeChars.test",
"tokenizer/unicodeCharsProblematic.test",
"tokenizer/xmlViolation.test",
])