name: CI on: push: branches: - "main" pull_request: jobs: test: runs-on: cimaster-latest steps: - name: ๐Ÿ‘๏ธ Checkout repository uses: actions/checkout@v4 - name: ๐Ÿฆ€ Setup Rust cache uses: https://github.com/Swatinem/rust-cache@v2 with: cache-on-failure: "true" - name: ๐Ÿ“Ž Clippy run: cargo clippy --all -- -D warnings - name: ๐Ÿงช Test run: | ./tests/testfiles/sites/make_zip.sh cargo nextest run --config-file ~/.config/nextest.toml --profile ci --workspace - name: ๐Ÿ’Œ Upload test report if: always() uses: https://code.forgejo.org/forgejo/upload-artifact@v4 with: name: test path: target/nextest/ci/junit.xml - name: ๐Ÿ”— Artifactview PR comment if: ${{ always() && github.event_name == 'pull_request' }} run: | if [[ "$GITEA_ACTIONS" == "true" ]]; then RUN_NUMBER="$GITHUB_RUN_NUMBER"; else RUN_NUMBER="$GITHUB_RUN_ID"; fi echo "Run: $GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$RUN_NUMBER" echo "Pull: ${{ github.event.number }}" curl -SsL --fail-with-body -w "\n" -X POST https://av.thetadev.de/.well-known/api/prComment -H "Content-Type: application/json" \ --data '{"url": "'"$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$RUN_NUMBER"'", "pr": ${{ github.event.number }}, "artifact_titles": {"test":"๐Ÿงช Test report"}, "artifact_paths": {"test":"/junit.xml?viewer=1"}}'