this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

ci: add workflow for e2e tests

Khue Doan 6bf587f5 6de0d366

+67
+67
.github/workflows/test-e2e.yml
··· 1 + name: Test E2E 2 + 3 + on: 4 + workflow_dispatch: 5 + pull_request: 6 + paths: 7 + - ".github/workflows/test-e2e.yml" 8 + - "Makefile" 9 + - "examples/**" 10 + - "tests/e2e/**" 11 + - "cmd/**" 12 + - "internal/**" 13 + - "flake.nix" 14 + - "go.mod" 15 + - "go.sum" 16 + 17 + jobs: 18 + test-e2e: 19 + runs-on: ubuntu-latest 20 + timeout-minutes: 240 21 + permissions: 22 + contents: read 23 + env: 24 + NIXIE_E2E_WORKDIR: ${{ github.workspace }}/artifacts/e2e 25 + 26 + steps: 27 + - name: Check out repository 28 + uses: actions/checkout@v4 29 + 30 + - name: Free runner disk space 31 + run: | 32 + sudo rm -rf /usr/local/lib/android 33 + sudo rm -rf /opt/ghc 34 + sudo rm -rf /usr/share/dotnet 35 + sudo rm -rf /usr/local/.ghcup 36 + df -h 37 + 38 + - name: Install Nix 39 + uses: DeterminateSystems/nix-installer-action@v16 40 + with: 41 + extra-conf: | 42 + experimental-features = nix-command flakes 43 + 44 + - name: Enable Nix binary cache 45 + uses: DeterminateSystems/magic-nix-cache-action@v8 46 + 47 + - name: Show virtualization support 48 + run: | 49 + ls -l /dev/kvm || true 50 + grep -E 'vmx|svm' /proc/cpuinfo | head || true 51 + 52 + - name: Run end-to-end test 53 + run: | 54 + mkdir -p "$NIXIE_E2E_WORKDIR" 55 + sudo env PATH="$PATH" NIXIE_E2E_WORKDIR="$NIXIE_E2E_WORKDIR" "$(command -v nix)" run -L ./examples#e2e 56 + 57 + - name: Relax permissions on artifacts 58 + if: always() 59 + run: sudo chmod -R a+rX "${NIXIE_E2E_WORKDIR%/*}" || true 60 + 61 + - name: Upload end-to-end artifacts 62 + if: always() 63 + uses: actions/upload-artifact@v4 64 + with: 65 + name: test-e2e-artifacts 66 + path: ${{ env.NIXIE_E2E_WORKDIR }} 67 + if-no-files-found: ignore