Skip to content

Commit ea5dfac

Browse files
committed
remove test_call_checks_keys
1 parent c804e5e commit ea5dfac

1 file changed

Lines changed: 0 additions & 22 deletions

File tree

tests/unit/autojac/_transform/test_base.py

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -31,28 +31,6 @@ def check_keys(self) -> tuple[set[Tensor], set[Tensor]]:
3131
return self._required_keys, self._output_keys
3232

3333

34-
def test_call_checks_keys():
35-
"""
36-
Tests that a ``Transform`` checks that the provided dictionary to the `__call__` function
37-
contains keys that correspond exactly to `required_keys`.
38-
"""
39-
40-
a1 = torch.randn([2])
41-
a2 = torch.randn([3])
42-
t = FakeTransform(required_keys={a1}, output_keys={a1, a2})
43-
44-
t(TensorDict({a1: a2}))
45-
46-
with raises(ValueError):
47-
t(TensorDict({a2: a1}))
48-
49-
with raises(ValueError):
50-
t(TensorDict({}))
51-
52-
with raises(ValueError):
53-
t(TensorDict({a1: a2, a2: a1}))
54-
55-
5634
def test_compose_checks_keys():
5735
"""
5836
Tests that the composition of ``Transform``s checks that the inner transform's `output_keys`

0 commit comments

Comments
 (0)