Skip to content

Update test_shape.py #1477

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: labeled_tensors
Choose a base branch
from
Open
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
8 changes: 0 additions & 8 deletions tests/xtensor/test_shape.py
Original file line number Diff line number Diff line change
Expand Up @@ -346,14 +346,6 @@ def test_squeeze_errors():
with pytest.raises(ValueError, match="has static size .* not 1"):
x1.squeeze("city")

# Symbolic shape: dim is not 1 at runtime → should raise
x2 = xtensor("x2", dims=("a", "b", "c")) # shape unknown
y2 = x2.squeeze("b")
x2_test = xr_arange_like(xtensor(dims=x2.dims, shape=(2, 2, 3)))
fn2 = xr_function([x2], y2)
with pytest.raises(Exception):
fn2(x2_test)


def test_expand_dims():
"""Test expand_dims."""
Expand Down