Add back UPB numpy test now that it has been moved in the protobuf directory.

This also includes an update to the newest protobuf commit.

PiperOrigin-RevId: 525551351
pull/13171/head
Deanna Garcia 2 years ago committed by Copybara-Service
parent 55cfaf3e0c
commit 8c10056074
  1. 4
      bazel/workspace_deps.bzl
  2. 20
      python/pb_unit_tests/BUILD
  3. 2
      python/pb_unit_tests/numpy_test_wrapper.py

@ -23,8 +23,8 @@ def upb_deps():
_github_archive,
name = "com_google_protobuf",
repo = "https://github.com/protocolbuffers/protobuf",
commit = "6ae84761bf09db1b9da6c7fed4d708468017b79f",
sha256 = "1213f82d140326d2d0c570f7114df0478ac61918f25e780ccf99040dff2bec79",
commit = "13833b1df01b811c6b0a3a2c83864579d740050f",
sha256 = "b029d1a5f84b3f0f424f7524101e3104fae8c59bb3a6104b9cec451b14b3d3e8",
patches = ["@upb//bazel:protobuf.patch"],
)

@ -47,10 +47,22 @@ pyproto_test_wrapper(name = "keywords_test")
pyproto_test_wrapper(name = "message_factory_test")
# begin:github_only
# pyproto_test_wrapper(
# name = "numpy_test",
# deps = [requirement("numpy")],
# )
# This target has different dependencies and fails when using the wrapper
# TODO: Move this to using pyproto_test_wrapper
py_test(
name = "numpy_test",
srcs = ["numpy_test_wrapper.py"],
main = "numpy_test_wrapper.py",
deps = [
requirement("numpy"),
"@com_google_protobuf//python/google/protobuf/internal/numpy:numpy_test",
"//python:_message",
],
target_compatible_with = select({
"@system_python//:supported": [],
"//conditions:default": ["@platforms//:incompatible"],
}),
)
# end:github_only
# begin:google_only

@ -25,7 +25,7 @@
import unittest
from google.protobuf.internal.numpy_test import *
from google.protobuf.internal.numpy.numpy_test import *
if __name__ == '__main__':
unittest.main(verbosity=2)

Loading…
Cancel
Save