Use `.cancel_called` over deprecated `ActorNursery.cancelled`
`tests.test_cancellation` asserted on `ActorNursery.cancelled`, which now warns + redirects to `.cancel_called`. Swap to the non-deprecated property so the suite stops tripping its own `DeprecationWarning`. (this patch was generated in some part by [`claude-code`][claude-code-gh]) [claude-code-gh]: https://github.com/anthropics/claude-codewkt/rm_test_warnings
parent
c4dee6ab4b
commit
725c4ef212
|
|
@ -351,7 +351,7 @@ async def test_cancel_infinite_streamer(
|
|||
|
||||
# we support trio's cancellation system
|
||||
assert cancel_scope.cancelled_caught
|
||||
assert n.cancelled
|
||||
assert n.cancel_called
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
|
|
@ -465,7 +465,7 @@ async def test_some_cancels_all(
|
|||
elif isinstance(err, tractor.RemoteActorError):
|
||||
assert err.boxed_type == err_type
|
||||
|
||||
assert an.cancelled is True
|
||||
assert an.cancel_called is True
|
||||
assert not an._children
|
||||
else:
|
||||
pytest.fail("Should have gotten a remote assertion error?")
|
||||
|
|
|
|||
Loading…
Reference in New Issue