Files
logos-tutorial/.github/workflows/ci.yml
Iuri Matias b444f765fa automate tutorial following
automate tutorial following

improve test specs; ensure basecamp tests are being run

replicate issue; run tests in the CI

merge actions
2026-05-27 14:48:27 -04:00

66 lines
2.1 KiB
YAML

name: Tutorial Tests
on:
pull_request:
branches: [master, main]
push:
branches: [master, main]
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
jobs:
tutorial-tests:
name: Tutorial Tests (${{ matrix.os }})
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@main
- name: Setup Cachix
uses: cachix/cachix-action@v15
with:
name: logos-co
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- name: Build lm (module inspector)
run: nix build github:logos-co/logos-module#lm -o result-lm -L
- name: Build logos-basecamp
run: nix build github:logos-co/logos-basecamp -o result-basecamp -L
- name: Build logos-qt-mcp
run: nix build github:logos-co/logos-basecamp#logos-qt-mcp -o result-mcp -L
- name: Test - Wrapping a C Library
run: |
export PATH="$PWD/result-lm/bin:$PATH"
WORKDIR=$(mktemp -d)
nix-shell -p yq-go nodejs --run \
"./tests/run-tutorial-test.sh tests/tutorial-wrapping-c-library.test.yaml --workdir $WORKDIR --basecamp-bin $PWD/result-basecamp/bin/LogosBasecamp --qt-mcp $PWD/result-mcp --verbose"
- name: Test - QML UI App
run: |
export PATH="$PWD/result-lm/bin:$PATH"
WORKDIR=$(mktemp -d)
nix-shell -p yq-go nodejs --run \
"./tests/run-tutorial-test.sh tests/tutorial-qml-ui-app.test.yaml --workdir $WORKDIR --basecamp-bin $PWD/result-basecamp/bin/LogosBasecamp --qt-mcp $PWD/result-mcp --verbose"
- name: Test - C++ UI Module
run: |
export PATH="$PWD/result-lm/bin:$PATH"
WORKDIR=$(mktemp -d)
nix-shell -p yq-go nodejs --run \
"./tests/run-tutorial-test.sh tests/tutorial-cpp-ui-app.test.yaml --workdir $WORKDIR --basecamp-bin $PWD/result-basecamp/bin/LogosBasecamp --qt-mcp $PWD/result-mcp --verbose"