From 30f442fdfeaebc3978a8353756fa1c150c1c7832 Mon Sep 17 00:00:00 2001 From: YuviPanda Date: Wed, 14 Feb 2024 22:19:47 -0800 Subject: [PATCH] Add a couple more debug log items --- integration-tests/test_vnc.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/integration-tests/test_vnc.py b/integration-tests/test_vnc.py index 18167215..076ca5d5 100644 --- a/integration-tests/test_vnc.py +++ b/integration-tests/test_vnc.py @@ -97,6 +97,7 @@ def test_vnc_screenshot(container, image_diff, unused_tcp_port): f'ws://{origin}/desktop-websockify/?token={token}', ] ) + print(f"websocat proxying 127.0.0.1:{unused_tcp_port} to VNC server") try: # :: is used to indicate port, as that is what VNC expects. # A single : is used to indicate display number. In our case, we @@ -104,9 +105,10 @@ def test_vnc_screenshot(container, image_diff, unused_tcp_port): with api.connect( f'127.0.0.1::{unused_tcp_port}' ) as client, tempfile.TemporaryDirectory() as d: - screenshot_target = Path(d) / "screenshot.jpeg" + print("Connected to VNC server. Attempting to capture screenshot...") # Wait a couple of seconds for the desktop to fully render time.sleep(5) + screenshot_target = Path(d) / "screenshot.jpeg" client.captureScreen(str(screenshot_target)) # This asserts if the images are different, so test will fail