Skip to content

Commit

Permalink
ci: Enable tests on Windows OS
Browse files Browse the repository at this point in the history
  • Loading branch information
kesara committed Oct 17, 2024
1 parent dce083d commit 2181f87
Showing 1 changed file with 45 additions and 46 deletions.
91 changes: 45 additions & 46 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -149,49 +149,48 @@ jobs:
run: |
echo "/usr/local/opt/make/libexec/gnubin" >> $GITHUB_PATH
tox
# tests-windows:
# name: Unit Tests (Windows)
# runs-on: windows-latest
# if: github.event_name == 'pull_request'

# strategy:
# matrix:
# python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']

# steps:
# - name: Checkout repository
# uses: actions/checkout@v4

# - name: Setup Python ${{ matrix.python-version }}
# uses: actions/setup-python@v5
# with:
# python-version: ${{ matrix.python-version }}

# - name: Install Fonts
# shell: pwsh
# working-directory: .github/scripts
# run: |
# Invoke-WebRequest -Uri 'https://github.com/ietf-tools/common/raw/main/scripts/font-install/font-install.exe' -OutFile font-install.exe
# & ./font-install.exe -debug https://fonts.google.com/download?family=Roboto%20Mono
# & ./font-install.exe -debug https://noto-website-2.storage.googleapis.com/pkgs/Noto-unhinted.zip

# - name: Install dependencies
# shell: pwsh
# run: |
# Invoke-WebRequest -Uri 'https://github.com/tschoonj/GTK-for-Windows-Runtime-Environment-Installer/releases/download/2022-01-04/gtk3-runtime-3.24.31-2022-01-04-ts-win64.exe' -OutFile gtk.exe
# & ./gtk.exe /S
# choco install make
# echo "Installing pip + wheel..."
# python -m pip install --upgrade pip wheel
# echo "Installing requirements.txt + test dependencies..."
# python -m pip install -r requirements.txt tox tox-gh-actions certifi decorator dict2xml pyflakes "pypdf>=4.1.0" "weasyprint==61.2" "pydyf<0.10.0"
# - name: Generate Valid Tests
# run: |
# make yestests || true
# cp tests/out/. tests/valid

# - name: Test with tox
# env:
# PLATFORM: windows-latest
# run: tox
tests-windows:
name: Unit Tests (Windows)
runs-on: windows-latest
if: github.event_name == 'pull_request'

strategy:
matrix:
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install Fonts
shell: pwsh
working-directory: .github/scripts
run: |
Invoke-WebRequest -Uri 'https://github.com/ietf-tools/common/raw/main/scripts/font-install/font-install.exe' -OutFile font-install.exe
& ./font-install.exe -debug https://github.com/ietf-tools/xml2rfc-fonts/archive/refs/tags/3.22.0.zip
- name: Install dependencies
shell: pwsh
run: |
Invoke-WebRequest -Uri 'https://github.com/tschoonj/GTK-for-Windows-Runtime-Environment-Installer/releases/download/2022-01-04/gtk3-runtime-3.24.31-2022-01-04-ts-win64.exe' -OutFile gtk.exe
& ./gtk.exe /S
choco install make
echo "Installing pip + wheel..."
python -m pip install --upgrade pip wheel
echo "Installing requirements.txt + test dependencies..."
python -m pip install -r requirements.txt tox tox-gh-actions certifi decorator dict2xml pyflakes "pypdf>=4.1.0" "weasyprint==61.2" "pydyf<0.10.0"
- name: Generate Valid Tests
run: |
make yestests || true
cp tests/out/. tests/valid
- name: Test with tox
env:
PLATFORM: windows-latest
run: tox

0 comments on commit 2181f87

Please sign in to comment.