Skip to content

Commit

Permalink
Fix test_batchsize_reset
Browse files Browse the repository at this point in the history
  • Loading branch information
tcbegley committed Feb 9, 2023
1 parent 6fe9382 commit 7a05d2c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/test_tensordict.py
Original file line number Diff line number Diff line change
Expand Up @@ -2489,8 +2489,8 @@ def test_batchsize_reset():
# test index
td[torch.tensor([1, 2])]
with pytest.raises(
IndexError,
match=re.escape("too many indices for tensor of dimension 1"),
RuntimeError,
match=re.escape("The shape torch.Size([3]) is incompatible with the index"),
):
td[:, 0]

Expand Down

0 comments on commit 7a05d2c

Please sign in to comment.