Skip to content

RuntimeWarning in test_unittest #128729

@serhiy-storchaka

Description

@serhiy-storchaka
$ ./python -We -m test -vuall test_unittest -m test_deprecation_of_return_val_from_test_async_method
...
test_deprecation_of_return_val_from_test_async_method (test.test_unittest.test_case.Test_TestCase.test_deprecation_of_return_val_from_test_async_method) ... Warning -- Unraisable exception
Exception ignored in: <coroutine object Test_TestCase.test_deprecation_of_return_val_from_test_async_method.<locals>.Foo.test1 at 0x7f5c24cb3a10>
Traceback (most recent call last):
  File "/home/serhiy/py/cpython/Lib/warnings.py", line 691, in _warn_unawaited_coroutine
    warn(msg, category=RuntimeWarning, stacklevel=2, source=coro)
RuntimeWarning: coroutine 'Test_TestCase.test_deprecation_of_return_val_from_test_async_method.<locals>.Foo.test1' was never awaited
ok
...

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.14bugs and security fixestestsTests in the Lib/test dir

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions