mirror of
https://github.com/hanzoui/pyisolate.git
synced 2026-10-30 20:37:17 +00:00
Drop Python 3.9, add bubblewrap to workflows, apply ruff formatting. Was running `ruff` and not the additional `ruff-format`. Installed pre-commit hooks to prevent any future non-compliant commits.
27 lines
696 B
Python
27 lines
696 B
Python
import logging
|
|
import sys
|
|
|
|
import pytest
|
|
|
|
# Configure logging to see what's happening
|
|
logging.basicConfig(level=logging.DEBUG, stream=sys.stderr)
|
|
logging.getLogger("pyisolate").setLevel(logging.DEBUG)
|
|
|
|
|
|
@pytest.mark.asyncio
|
|
async def test_debug_ping(reference_host):
|
|
print("\n--- Starting Debug Ping ---")
|
|
ext = reference_host.load_test_extension("debug_ping", isolated=True)
|
|
|
|
print(f"Extension loaded: {ext}")
|
|
proxy = ext.get_proxy()
|
|
print(f"Proxy obtained: {proxy}")
|
|
|
|
try:
|
|
response = await proxy.ping()
|
|
print(f"Ping response: {response}")
|
|
assert response == "pong"
|
|
except Exception as e:
|
|
print(f"Ping failed with: {e}")
|
|
raise
|