# Gitea Actions — Tests # # Dedicated test workflow: builds the application and runs the full test suite # (ctest) on every push and pull request. Kept separate from the release # workflow so a failing test never blocks a release. name: tests on: push: pull_request: workflow_dispatch: jobs: build-test: runs-on: linux steps: - name: Checkout uses: actions/checkout@v4 - name: Install dependencies run: | # Host-mode runners execute jobs directly on the runner machine, so # detect its package manager instead of hardcoding apt (which only # exists on Debian/Ubuntu hosts). if command -v pacman >/dev/null 2>&1; then sudo pacman -S --noconfirm --needed \ git cmake gcc make qt6-base elif command -v apt-get >/dev/null 2>&1; then sudo apt-get update sudo apt-get install -y \ git cmake g++ make qt6-base-dev elif command -v dnf >/dev/null 2>&1; then sudo dnf install -y \ git cmake gcc-c++ make qt6-qtbase-devel else echo "Unsupported package manager: install git, cmake, a C++ compiler, make and Qt6 manually" >&2 exit 1 fi - name: Configure run: | cmake -B build \ -DFWS_BUILD_EXAMPLE_PLUGIN=ON \ -DCMAKE_BUILD_TYPE=Release - name: Build run: | cmake --build build -j$(nproc) - name: Run all tests run: | cd build ctest --output-on-failure