Re-enabled conformance tests.

pull/13171/head
Joshua Haberman 6 years ago
parent e294a16c08
commit cbe051a09c
  1. 78
      BUILD
  2. 1
      CMakeLists.txt
  3. 7
      WORKSPACE
  4. 4
      tools/make_cmakelists.py

78
BUILD

@ -350,45 +350,45 @@ cc_test(
copts = CPPOPTS,
)
#upb_proto_library(
# name = "conformance_proto_upb",
# deps = ["@com_google_protobuf//:conformance_proto"],
#)
#upb_proto_library(
# name = "test_messages_proto3_proto_upb",
# deps = ["@com_google_protobuf//:test_messages_proto3_proto"],
#)
#cc_binary(
# name = "conformance_upb",
# srcs = [
# "tests/conformance_upb.c",
# ],
# copts = COPTS + ["-Ibazel-out/k8-fastbuild/bin"],
# deps = [
# ":conformance_proto_upb",
# ":test_messages_proto3_proto_upb",
# ":upb",
# ],
#)
#
#make_shell_script(
# name = "gen_test_conformance_upb",
# out = "test_conformance_upb.sh",
# contents = "$(rlocation com_google_protobuf/conformance_test_runner) $(rlocation upb/conformance_upb)",
#)
#
#sh_test(
# name = "test_conformance_upb",
# srcs = ["test_conformance_upb.sh"],
# data = [
# "tests/conformance_upb_failures.txt",
# ":conformance_upb",
# "@bazel_tools//tools/bash/runfiles",
# "@com_google_protobuf//:conformance_test_runner",
# ],
#)
upb_proto_library(
name = "conformance_proto_upb",
deps = ["@com_google_protobuf//:conformance_proto"],
)
upb_proto_library(
name = "test_messages_proto3_proto_upb",
deps = ["@com_google_protobuf//:test_messages_proto3_proto"],
)
cc_binary(
name = "conformance_upb",
srcs = [
"tests/conformance_upb.c",
],
copts = COPTS + ["-Ibazel-out/k8-fastbuild/bin"],
deps = [
":conformance_proto_upb",
":test_messages_proto3_proto_upb",
":upb",
],
)
make_shell_script(
name = "gen_test_conformance_upb",
out = "test_conformance_upb.sh",
contents = "$(rlocation com_google_protobuf/conformance_test_runner) $(rlocation upb/conformance_upb)",
)
sh_test(
name = "test_conformance_upb",
srcs = ["test_conformance_upb.sh"],
data = [
"tests/conformance_upb_failures.txt",
":conformance_upb",
"@bazel_tools//tools/bash/runfiles",
"@com_google_protobuf//:conformance_test_runner",
],
)
# Amalgamation #################################################################

@ -115,6 +115,7 @@ target_link_libraries(upb_pb
table
upb)
add_library(upb_json
generated_for_cmake/upb/json/parser.c
upb/json/printer.c
upb/json/parser.h
upb/json/printer.h)

@ -17,8 +17,11 @@ http_archive(
git_repository(
name = "com_google_protobuf",
commit = "ec1a70913e5793a7d0a7b5fbf7e0e4f75409dd41",
remote = "https://github.com/protocolbuffers/protobuf.git",
# TODO(haberman): update to protobuf branch oncd this is merged:
# https://github.com/protocolbuffers/protobuf/pull/6126
#remote = "https://github.com/protocolbuffers/protobuf.git",
commit = "2996da4d817dd006cd8599c74ad2364a897d6107",
remote = "https://github.com/haberman/protobuf.git",
)
http_archive(

@ -43,8 +43,8 @@ class BuildFileFunctions(object):
for file in files:
if os.path.isfile(file):
found_files.append(file)
elif os.path.isfile("generated/" + file):
found_files.append("generated/" + file)
elif os.path.isfile("generated_for_cmake/" + file):
found_files.append("generated_for_cmake/" + file)
else:
print("Warning: no such file: " + file)

Loading…
Cancel
Save