diff --git a/.appveyor.yml b/.appveyor.yml index e395f2ae6..5868061f4 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -17,11 +17,6 @@ environment: - PYTHON: C:/Python38-x64 - PYTHON: C:/Python35 - PYTHON: C:/Python35-x64 - - PYTHON: C:/msys64/mingw32 - EXECUTABLE: bin/python3 - PIP_DIR: bin - TEST_OPTIONS: --processes=0 - DEPLOY: NO - PYTHON: C:/vp/pypy3 EXECUTABLE: bin/pypy.exe VENV: YES @@ -41,33 +36,17 @@ install: c:\pillow\winbuild\appveyor_install_pypy3.cmd } - ps: | - if ($env:PYTHON -eq "c:/msys64/mingw32") - { - c:\msys64\usr\bin\bash -l -c c:\\pillow\\winbuild\\appveyor_install_msys2_deps.sh - } - else - { c:\python37\python.exe c:\pillow\winbuild\build_dep.py c:\pillow\winbuild\build_deps.cmd $host.SetShouldExit(0) - } - curl -fsSL -o gs952.exe https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs952/gs952w32.exe - gs952.exe /S - path %path%;C:\Program Files (x86)\gs\gs9.52\bin build_script: - ps: | - if ($env:PYTHON -eq "c:/msys64/mingw32") - { - c:\msys64\usr\bin\bash -l -c c:\\pillow\\winbuild\\appveyor_build_msys2.sh - Write-Host "through install" - $host.SetShouldExit(0) - } - else - { & $env:PYTHON/$env:EXECUTABLE c:\pillow\winbuild\build.py $host.SetShouldExit(0) - } - cd c:\pillow - '%PYTHON%\%EXECUTABLE% selftest.py --installed' diff --git a/.github/workflows/test-windows.yml b/.github/workflows/test-windows.yml index d45dc9467..d8ffd5172 100644 --- a/.github/workflows/test-windows.yml +++ b/.github/workflows/test-windows.yml @@ -385,3 +385,55 @@ jobs: with: name: ${{ steps.wheel.outputs.dist }} path: dist + + msys: + runs-on: windows-2019 + + strategy: + fail-fast: false + matrix: + mingw: ["MINGW32", "MINGW64"] + include: + - mingw: "MINGW32" + package: "mingw-w64-i686" + - mingw: "MINGW64" + package: "mingw-w64-x86_64" + + defaults: + run: + shell: bash.exe --login "{0}" + env: + MSYSTEM: ${{ matrix.mingw }} + CHERE_INVOKING: 1 + + timeout-minutes: 30 + name: MSYS2 ${{ matrix.mingw }} + + steps: + - uses: actions/checkout@v2 + + - name: Set up MSYS + run: echo ::add-path::C:\msys64\usr\bin\ + shell: pwsh + + - name: Install MinGW packages + run: | + pacman -S --noconfirm \ + ${{ matrix.package }}-python3-pip \ + ${{ matrix.package }}-python3-setuptools \ + ${{ matrix.package }}-python3-pytest \ + ${{ matrix.package }}-python3-pytest-cov \ + ${{ matrix.package }}-python3-olefile \ + ${{ matrix.package }}-libjpeg-turbo \ + ${{ matrix.package }}-libimagequant + python3 -m pip install -U pip codecov + + - name: Build Pillow + run: | + python3 setup.py install + + - name: Test Pillow + run: | + python3 selftest.py --installed + python3 -m pytest -vx --cov PIL --cov Tests --cov-report term --cov-report xml Tests + codecov --file coverage.xml --name MSYS2 ${{ matrix.mingw }}