Fix test typo + use `wait_for_result()` API

- "boostrap" → "bootstrap" in mod docstring
- replace deprecated `portal.result()` with
  `portal.wait_for_result()` + value assertion
  inside the nursery block

Review: PR #1 (Copilot)
https://github.com/mahmoudhas/tractor/pull/1#pullrequestreview-4091096072

(this patch was generated in some part by [`claude-code`][claude-code-gh])
[claude-code-gh]: https://github.com/anthropics/claude-code
subint_spawner_backend
Gud Boi 2026-04-10 14:55:09 -04:00 committed by mahmoudhas
parent a0a7668670
commit 570c975f14
1 changed files with 3 additions and 2 deletions

View File

@ -1,7 +1,7 @@
""" """
Spawning basics including audit of, Spawning basics including audit of,
- subproc boostrap, such as subactor runtime-data/config inheritance, - subproc bootstrap, such as subactor runtime-data/config inheritance,
- basic (and mostly legacy) `ActorNursery` subactor starting and - basic (and mostly legacy) `ActorNursery` subactor starting and
cancel APIs. cancel APIs.
@ -160,7 +160,8 @@ async def test_most_beautiful_word(
name='some_linguist', name='some_linguist',
) )
print(await portal.result()) res: Any = await portal.wait_for_result()
assert res == return_value
# The ``async with`` will unblock here since the 'some_linguist' # The ``async with`` will unblock here since the 'some_linguist'
# actor has completed its main task ``cellar_door``. # actor has completed its main task ``cellar_door``.