Feat: GitHub Actions workflow for linting and tests #7
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: [pull_request] | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Set up Rust toolchain | |
| uses: hecrj/setup-rust-action@v2 | |
| with: | |
| rust-version: stable | |
| - name: Check out the code | |
| uses: actions/checkout@v4 | |
| - name: Install Clippy | |
| run: rustup component add clippy | |
| - name: Run Clippy | |
| run: cargo clippy --all-targets --all-features -- -D warnings | |
| test: | |
| needs: lint | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| test_name: [ | |
| "tests::basic_test", | |
| "tests::test_health_endpoint", | |
| "tests::test_join_group", | |
| "tests::test_refresh_empty_group", | |
| "tests::test_refresh_group_with_file", | |
| "tests::test_refresh_group_with_single_repo", | |
| "tests::test_refresh_joined_group", | |
| "tests::test_refresh_nonexistent_group", | |
| "tests::test_replicate_group", | |
| "tests::test_upload_list_delete" | |
| ] | |
| steps: | |
| - name: Set up Rust toolchain | |
| uses: hecrj/setup-rust-action@v2 | |
| with: | |
| rust-version: stable | |
| - name: Check out the code | |
| uses: actions/checkout@v4 | |
| - name: Run individual test | |
| env: | |
| RUST_MIN_STACK: 8388608 | |
| run: cargo test --verbose -- ${{ matrix.test_name }} --test-threads=1 --nocapture |