MCPcopy Create free account
hub / github.com/Dstack-TEE/dstack / test_async_tappd_client_deprecated

Function test_async_tappd_client_deprecated

sdk/python/tests/test_client.py:513–528  ·  view source on GitHub ↗

Test that AsyncTappdClient shows deprecation warning.

()

Source from the content-addressed store, hash-verified

511
512# Test AsyncTappdClient
513def test_async_tappd_client_deprecated():
514 """Test that AsyncTappdClient shows deprecation warning."""
515 with warnings.catch_warnings(record=True) as w:
516 warnings.simplefilter("always")
517 AsyncTappdClient()
518
519 # Filter for AsyncTappdClient deprecation warnings specifically
520 tappd_warnings = [
521 warning
522 for warning in w
523 if issubclass(warning.category, DeprecationWarning)
524 and "AsyncTappdClient is deprecated" in str(warning.message)
525 ]
526
527 assert len(tappd_warnings) == 1
528 assert "AsyncTappdClient is deprecated" in str(tappd_warnings[0].message)
529
530
531@pytest.mark.asyncio

Callers

nothing calls this directly

Calls 1

AsyncTappdClientClass · 0.90

Tested by

no test coverage detected