From 46b2db98562215e83d46d78869d48049e7161822 Mon Sep 17 00:00:00 2001 From: Kaleb Barrett Date: Sat, 31 May 2025 12:31:19 -0600 Subject: [PATCH 1/2] Add MING32 and UCRT64 tests and simplify --- .github/workflows/tests.yml | 52 +++++++------------------------------ 1 file changed, 10 insertions(+), 42 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 708b3ed..f1821b8 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -170,58 +170,26 @@ jobs: matrix: msystem: - MSYS + - MINGW32 - MINGW64 + - UCRT64 steps: - - name: Install msys2 (MINGW64) - if: matrix.msystem == 'MINGW64' + - name: Install msys2 uses: msys2/setup-msys2@v2 with: - msystem: MINGW64 - install: >- - mingw-w64-x86_64-toolchain - mingw-w64-x86_64-gnupg - mingw-w64-x86_64-python - mingw-w64-x86_64-python-pip - update: true - - name: Install msys2 (MSYS) - if: matrix.msystem == 'MSYS' - uses: msys2/setup-msys2@v2 - with: - msystem: MSYS - install: >- - msys2-devel + msystem: ${{ matrix.msystem }} + pacboy: >- gnupg - python - python-pip - python-devel + python:p + python-pip:p update: true - uses: actions/checkout@v4 - - name: Build venv + - name: Run tests run: | python -m venv .venv - - name: Install package - run: | - . .venv/bin/activate - pip install . - - name: Print libpython - run: | . .venv/bin/activate - echo 'NAMES' - find_libpython -v --candidate-names - echo 'PATHS' - find_libpython -v --candidate-paths - echo 'LOCATION' - find_libpython -v - - name: Install Testing Requirements - run: | - . .venv/bin/activate - pip install pytest pytest-cov coverage - - name: Run Tests - run: | - . .venv/bin/activate - pytest --cov --cov-branch tests/ - pytest --cov --cov-branch --cov-append --doctest-modules $(python -c 'import find_libpython; print(find_libpython.__file__)') - coverage xml -o coverage.xml + pip install nox + nox -e tests - name: Upload to codecov uses: codecov/codecov-action@v4 with: From ffbbe3ac14178df9f1e76824d3cf4edfeb82d2ef Mon Sep 17 00:00:00 2001 From: Kaleb Barrett Date: Sat, 31 May 2025 12:54:16 -0600 Subject: [PATCH 2/2] Use editable install when testing with nox --- noxfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/noxfile.py b/noxfile.py index 78caa99..1017e60 100644 --- a/noxfile.py +++ b/noxfile.py @@ -10,7 +10,7 @@ @nox.session def tests(session): # install current module and runtime dependencies - session.install(".") + session.install("-e", ".") # install testing dependencies session.install(*test_reqs)