diff --git a/BUILD b/BUILD index 1124321602b5..07ee629a18a6 100644 --- a/BUILD +++ b/BUILD @@ -14,38 +14,6 @@ exports_files(["LICENSE"]) # build configuration ################################################################################ -# TODO(yannic): Remove in 3.14.0. -string_flag( - name = "incompatible_use_com_google_googletest", - build_setting_default = "true", - values = ["true", "false"] -) - -config_setting( - name = "use_com_google_googletest", - flag_values = { - "//:incompatible_use_com_google_googletest": "true" - }, -) - -GTEST = select({ - "//:use_com_google_googletest": [ - "@com_google_googletest//:gtest", - ], - "//conditions:default": [ - "//external:gtest", - ], -}) - -GTEST_MAIN = select({ - "//:use_com_google_googletest": [ - "@com_google_googletest//:gtest_main", - ], - "//conditions:default": [ - "//external:gtest_main", - ], -}) - ################################################################################ # ZLIB configuration ################################################################################ @@ -571,6 +539,7 @@ COMMON_TEST_SRCS = [ cc_binary( name = "test_plugin", + testonly = True, srcs = [ # AUTOGEN(test_plugin_srcs) "src/google/protobuf/compiler/mock_code_generator.cc", @@ -580,7 +549,8 @@ cc_binary( deps = [ ":protobuf", ":protoc_lib", - ] + GTEST, + "@com_google_googletest//:gtest", + ], ) cc_test( @@ -592,7 +562,9 @@ cc_test( ], deps = [ ":protobuf_lite", - ] + GTEST_MAIN, + "@com_google_googletest//:gtest", + "@com_google_googletest//:gtest_main", + ], ) cc_test( @@ -695,7 +667,9 @@ cc_test( ":cc_test_protos", ":protobuf", ":protoc_lib", - ] + PROTOBUF_DEPS + GTEST_MAIN, + "@com_google_googletest//:gtest", + "@com_google_googletest//:gtest_main", + ] + PROTOBUF_DEPS, ) ################################################################################ diff --git a/WORKSPACE b/WORKSPACE index 5a767a97c0ac..d9ed7c883f5c 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -29,18 +29,6 @@ bind( actual = "//util/python:python_headers", ) -# TODO(yannic): Remove in 3.14.0. -bind( - name = "gtest", - actual = "@com_google_googletest//:gtest", -) - -# TODO(yannic): Remove in 3.14.0. -bind( - name = "gtest_main", - actual = "@com_google_googletest//:gtest_main", -) - jvm_maven_import_external( name = "guava_maven", artifact = "com.google.guava:guava:18.0",