File tree Expand file tree Collapse file tree 2 files changed +30
-0
lines changed
Expand file tree Collapse file tree 2 files changed +30
-0
lines changed Original file line number Diff line number Diff line change 99 build-requirements-path :
1010 description : ' Path to the build requirements file'
1111 required : true
12+ test-pip :
13+ description : ' Optional flag to also test installation with pip'
14+ required : false
15+ default : ' false'
1216
1317runs :
1418 using : " composite"
4549 print(f"Linked Against: {backend._ffi.string(backend._lib.OPENSSL_VERSION_TEXT).decode('ascii')}")
4650 EOF
4751 shell : bash
52+
53+ - name : Create virtual environment for pip testing
54+ if : inputs.test-pip == 'true'
55+ run : |
56+ if [ -n "${{ inputs.python-path }}" ]; then
57+ "${{ inputs.python-path }}" -m venv .venv-pip-test
58+ else
59+ python3 -m venv .venv-pip-test
60+ fi
61+ shell : bash
62+
63+ - name : Install cryptography wheel with pip
64+ if : inputs.test-pip == 'true'
65+ run : .venv-pip-test/bin/pip install cryptography --no-index -f wheelhouse/
66+ shell : bash
67+
68+ - name : Verify pip installation and OpenSSL version
69+ if : inputs.test-pip == 'true'
70+ run : |
71+ .venv-pip-test/bin/python - <<'EOF'
72+ from cryptography.hazmat.backends.openssl.backend import backend
73+ print(f"pip install - Loaded: {backend.openssl_version_text()}")
74+ print(f"pip install - Linked Against: {backend._ffi.string(backend._lib.OPENSSL_VERSION_TEXT).decode('ascii')}")
75+ EOF
76+ shell : bash
Original file line number Diff line number Diff line change @@ -168,6 +168,7 @@ jobs:
168168 with :
169169 python-path : /opt/python/${{ matrix.PYTHON.VERSION }}/bin/python
170170 build-requirements-path : ${{ env.BUILD_REQUIREMENTS_PATH }}
171+ test-pip : ${{ startsWith(matrix.PYTHON.VERSION, 'cp') }}
171172
172173 - uses : actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
173174 with :
You can’t perform that action at this time.
0 commit comments