Skip to content

Fan max RPM is hardcoded to 1500. There are fans of 1500, 2200 and 3000 #792

Fan max RPM is hardcoded to 1500. There are fans of 1500, 2200 and 3000

Fan max RPM is hardcoded to 1500. There are fans of 1500, 2200 and 3000 #792

name: Simple program (Windows)
on:
push:
branches:
- main
- 'releases/**'
pull_request:
jobs:
simple-program:
name: Simple program (Windows)
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r requirements.txt
- name: Run simple-program.py during 20 seconds
run: |
# For tests there is no real HW: use simulated LCD mode
(Get-Content simple-program.py) -replace "^REVISION.*$","REVISION=`"SIMU`"" | Set-Content simple-program.py
# Run the program for 20s
Start-Process -NoNewWindow python3 simple-program.py -RedirectStandardOutput output.log -RedirectStandardError error.log
sleep 20
add-content output.log (get-content error.log)
- name: Check output for errors
run: |
echo "######## Output : ########"
cat output.log
$SEL = Select-String -Path output.log -Pattern "error"
if ($SEL -ne $null)
{
throw "Program failed to run, see output above"
}
$SEL = Select-String -Path output.log -Pattern "traceback"
if ($SEL -ne $null)
{
throw "Program failed to run, see output above"
}
$SEL = Select-String -Path output.log -Pattern "exception"
if ($SEL -ne $null)
{
throw "Program failed to run, see output above"
}
- name: Prepare screenshot for archiving
run: |
cp screencap.png screenshot-py${{ matrix.python-version }}.png
- name: Archive a screenshot
uses: actions/upload-artifact@v4
with:
name: screenshot-py${{ matrix.python-version }}
path: screenshot-*.png