Skip to content

Windows support

Windows support #30

Workflow file for this run

name: Continuous Integration
on:
pull_request:
push:
branches:
- master
tags: '*'
jobs:
test:
name: GitHub Actions Test
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
omc-version: [stable, nightly]
python-version: ['3.10']
include:
- os: windows-latest
librariesPath: ${{ env.APPDATA }}\.openmodelica\libraries

Check failure on line 20 in .github/workflows/test.yml

View workflow run for this annotation

GitHub Actions / Continuous Integration

Invalid workflow file

The workflow is not valid. .github/workflows/test.yml (Line: 20, Col: 28): Unrecognized named-value: 'env'. Located at position 1 within expression: env.APPDATA .github/workflows/test.yml (Line: 22, Col: 28): Unrecognized named-value: 'env'. Located at position 1 within expression: env.HOME
- os: ubuntu-latest
librariesPath: ${{ env.HOME }}/.openmodelica/libraries
fail-fast: false
runs-on: ${{ matrix.os }}
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup OpenModelica
uses: OpenModelica/setup-openmodelica@v1
with:
version: ${{ matrix.omc-version }}
packages: |
'omc'
libraries: |
'Modelica 4.0.0'
'PNlib 2.2.0'
omc-diff: true
- name: Setup Python3
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: 'pip' # caching pip dependencies
- name: Install Python dependencies
shell: bash
run: |
pip install -r requirements.txt
- name: Run library test
shell: bash
run: |
python test.py --branch="${{ matrix.omc-version }}" --noclean --verbose --libraries ${{ matrix.librariesPath }} configs/sanityCheck.json
- name: Generate HTML results
shell: bash
run: python report.py --branches="${{ matrix.omc-version }}" configs/sanityCheck.json
- name: Zip HTML results
shell: bash
run: |
python .github/scripts/archiveResults.py "PNlib" "2.2.0" "${{ matrix.omc-version }}" "html/"
- name: Verify that overview.html contains simulation and verification
shell: bash
run: |
if ! grep -q "<tr><td><a href=\"${{ matrix.omc-version }}/PNlib_2.2.0/PNlib_2.2.0.html\">${{ matrix.omc-version }}</a></td><td><a>93</a></td><td><a>93</a></td><td><a>92</a></td><td><a>92</a></td><td><a>92</a></td><td><a>92</a></td><td><a>92</a></td><td><a>91</a></td><td><a>90</a></td></tr></table>" overview.html; then
echo "Failed to find 93 simulating and 90 verifying models in overwiew.html:"
cat overview.html
exit 1
fi
- name: Archive sqlite3.db
uses: actions/upload-artifact@v4
if: always()
with:
name: ${{ matrix.os }}-${{ matrix.omc-version }}-sqlite3.db
path: |
sqlite3.db
- name: Archive HTML
uses: actions/upload-artifact@v4
if: always()
with:
name: ${{ matrix.os }}-${{ matrix.omc-version }}-PNlib.html
path: html/