Skip to content

Commit 6648215

Browse files
gh-920: Remove array-api-strict from xpb (#922)
Co-authored-by: Patrick J. Roddy <patrickjamesroddy@gmail.com>
1 parent 89d04c6 commit 6648215

File tree

1 file changed

+18
-4
lines changed

1 file changed

+18
-4
lines changed

tests/fixtures/array_backends.py

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -107,14 +107,28 @@ def xp(request: pytest.FixtureRequest) -> ModuleType:
107107

108108

109109
@pytest.fixture(
110-
params=[xp for name, xp in xp_available_backends.items() if name != "jax.numpy"],
110+
params=[
111+
xp
112+
for name, xp in xp_available_backends.items()
113+
if name not in {"array-api-strict", "jax.numpy"}
114+
],
111115
scope="session",
112116
)
113117
def xpb(request: pytest.FixtureRequest) -> ModuleType:
114118
"""
115-
Fixture for array backend.
116-
117-
Access array library functions using `xp.` in tests.
119+
Fixture for array backend to be used in benchmarks.
120+
121+
Access array library functions using `xpb.` in tests.
122+
123+
We are excluding array-api-strict and jax for two reasons
124+
1. Our use of array-api-strict is not for its performance but
125+
for checking our interface with array libraries. Additionally,
126+
users are unlikely to use array-api-strict with glass.
127+
Therefore, it is not worth benchmarking with array-api-strict.
128+
2. We did not previously support jax, therefore it does
129+
not _yet_ make sense to regression test jax as there is
130+
nothing to compare against, since jax is not supported by
131+
the older versions of glass.
118132
"""
119133
return request.param # type: ignore[no-any-return]
120134

0 commit comments

Comments
 (0)