Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

load("@jaxite//bazel:test_oss.bzl", "cpu_gpu_tpu_test", "gpu_tpu_test", "multichip_tpu_test", "tpu_test")
load("@rules_license//rules:license.bzl", "license")
load("@rules_python//python:defs.bzl", "py_library", "py_test")
load("@rules_python//python:defs.bzl", "py_library", "py_strict_test")

package(
default_applicable_licenses = [":license"],
Expand Down Expand Up @@ -38,7 +38,7 @@ py_library(
],
)

py_test(
py_strict_test(
name = "encode_test",
size = "small",
timeout = "long",
Expand All @@ -53,7 +53,7 @@ py_test(
],
)

py_test(
py_strict_test(
name = "encrypt_test",
size = "small",
timeout = "long",
Expand Down Expand Up @@ -430,7 +430,7 @@ cpu_gpu_tpu_test(
],
)

py_test(
py_strict_test(
name = "lut_test",
srcs = ["jaxite/jaxite_bool/lut_test.py"],
deps = [
Expand Down Expand Up @@ -475,7 +475,7 @@ multichip_tpu_test(
],
)

py_test(
py_strict_test(
name = "rns_test",
size = "small",
timeout = "moderate",
Expand All @@ -493,7 +493,7 @@ py_test(
],
)

py_test(
py_strict_test(
name = "rns_utils_test",
size = "small",
timeout = "moderate",
Expand Down Expand Up @@ -570,7 +570,7 @@ tpu_test(
],
)

py_test(
py_strict_test(
name = "math_test",
size = "small",
timeout = "moderate",
Expand Down
12 changes: 6 additions & 6 deletions bazel/test_oss.bzl
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"""Testing util helpers"""

load("@rules_python//python:defs.bzl", "py_test")
load("@rules_python//python:defs.bzl", "py_strict_test")

# This file is a shim to have the same Google-internal and external API
# for running jaxite on TPU and GPU tests. The internal API is not
Expand All @@ -25,7 +25,7 @@ def tpu_test(name, **kwargs):
if not kwargs.get("main"):
main = kwargs.get("srcs", ["%s.py" % name])[0]
kwargs.setdefault("main", main)
py_test(
py_strict_test(
name = name,
srcs = kwargs["srcs"],
size = kwargs["size"],
Expand All @@ -51,7 +51,7 @@ def cpu_tpu_test(name, **kwargs):
name: the name of the CPU test.
**kwargs: other args passed along to generated rules.
"""
py_test(name = name, **kwargs)
py_strict_test(name = name, **kwargs)

def gpu_tpu_test(name, **kwargs):
"""A shim that only generates CPU tests.
Expand All @@ -60,7 +60,7 @@ def gpu_tpu_test(name, **kwargs):
name: the name of the CPU test.
**kwargs: other args passed along to generated rules.
"""
py_test(name = name, **kwargs)
py_strict_test(name = name, **kwargs)

def cpu_gpu_tpu_test(name, **kwargs):
"""A shim that only generates CPU tests.
Expand All @@ -69,7 +69,7 @@ def cpu_gpu_tpu_test(name, **kwargs):
name: the name of the CPU test.
**kwargs: other args passed along to generated rules.
"""
py_test(name = name, **kwargs)
py_strict_test(name = name, **kwargs)

def cpu_gpu_tpu_py_benchmark(name, **kwargs):
"""A shim that only generates CPU tests.
Expand All @@ -79,4 +79,4 @@ def cpu_gpu_tpu_py_benchmark(name, **kwargs):
`_<platform>_benchmark`, e.g., `_cpu_benchmark`
**kwargs: other args passed along to generated rules.
"""
py_test(name = name + "_cpu_benchmark", **kwargs)
py_strict_test(name = name + "_cpu_benchmark", **kwargs)
Loading