diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 08a1031a8..9a6bea4a3 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -55,6 +55,8 @@ jobs: steps: - uses: mhils/workflows/checkout@34e9a0dabe3f355d60c385cdb1b1368c9219ecd3 - uses: mhils/workflows/setup-python@34e9a0dabe3f355d60c385cdb1b1368c9219ecd3 + with: + python-version: ${{ matrix.py }} - run: pip install tox - run: tox -e py if: matrix.os != 'ubuntu-latest' diff --git a/test/mitmproxy/proxy/layers/test_tls.py b/test/mitmproxy/proxy/layers/test_tls.py index 8d34aacc9..b132372b1 100644 --- a/test/mitmproxy/proxy/layers/test_tls.py +++ b/test/mitmproxy/proxy/layers/test_tls.py @@ -1,4 +1,5 @@ import ssl +import sys import time from logging import DEBUG from logging import WARNING @@ -485,7 +486,8 @@ class TestServerTLS: assert playbook assert tctx.server.tls_established - assert not tssl.obj.get_verified_chain() + if sys.version_info >= (3, 13): + assert not tssl.obj.get_verified_chain() tssl.obj.verify_client_post_handshake() with pytest.raises(ssl.SSLWantReadError): @@ -501,7 +503,8 @@ class TestServerTLS: tssl.bio_write(client_cert()) with pytest.raises(ssl.SSLWantReadError): tssl.obj.read(42) - assert tssl.obj.get_verified_chain() + if sys.version_info >= (3, 13): + assert tssl.obj.get_verified_chain() def make_client_tls_layer(