From f6fab0efa167bf6c6d00d4a5be9229a89b81cad7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?T=C3=96R=C3=96K=20Attila?= Date: Fri, 4 Oct 2024 11:36:21 +0200 Subject: [PATCH] Add a GHA workflow to run smoketests --- .github/workflows/smoketest.yml | 54 +++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 .github/workflows/smoketest.yml diff --git a/.github/workflows/smoketest.yml b/.github/workflows/smoketest.yml new file mode 100644 index 00000000..43b5a200 --- /dev/null +++ b/.github/workflows/smoketest.yml @@ -0,0 +1,54 @@ +name: Run smoke tests + +on: + push: + branches: + - main + - dev + pull_request: + branches: + - main + workflow_dispatch: + +jobs: + smoketests: + name: Smoke tests + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.x" + + - name: Install locally + run: python3 -m pip install -e . + + - name: '"Nixless" smoke test' + working-directory: tests + run: ./smoketest_nixless + + - uses: cachix/install-nix-action@v30 + with: + nix_path: nixpkgs=channel:nixos-unstable + + - name: '"List and info" smoke test' + working-directory: tests + run: ./smoketest_list_and_info + + - name: '"Install and run" smoke test' + working-directory: tests + run: ./smoketest_install_and_run + + - name: Show output + if: always() + run: | + echo "::group::Output" + cat tests/out.txt || echo '(no output)' + echo "::endgroup::" + + echo "::group::Cumulative output" + cat tests/cumulative_out.txt || echo '(no output)' + echo "::endgroup::"