Skip to content

Enhance README with real-world use case for Plex Media Server optimiz… #51

Enhance README with real-world use case for Plex Media Server optimiz…

Enhance README with real-world use case for Plex Media Server optimiz… #51

Workflow file for this run

name: Test Build
on:
pull_request:
branches: [ main ]
push:
branches: [ main ]
workflow_dispatch: # Allow manual triggering
jobs:
test-build:
name: Test Build ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install dependencies and run tests with coverage
run: make coverage
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
file: ./coverage.xml
fail_ci_if_error: false
verbose: true
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: Install PyInstaller for build test
shell: bash
run: |
if [[ "${{ runner.os }}" == "Windows" ]]; then
.venv/Scripts/python.exe -m pip install pyinstaller
else
.venv/bin/python -m pip install pyinstaller
fi
- name: Test PyInstaller build
shell: bash
run: |
# Set platform-specific variables for testing
if [[ "${{ runner.os }}" == "Windows" ]]; then
export OS="Windows_NT"
else
export OS="Linux"
fi
# Test that build command works
make build
# Test that the binary was created
if [[ "${{ runner.os }}" == "Windows" ]]; then
test -f dist/imgc.exe
./dist/imgc.exe --help
else
test -f dist/imgc
chmod +x dist/imgc
./dist/imgc --help
fi
- name: Upload test artifact
uses: actions/upload-artifact@v4
with:
name: test-build-${{ matrix.os }}
path: dist/
retention-days: 1