diff --git a/.gitea/workflows/checks.yaml b/.gitea/workflows/checks.yaml new file mode 100644 index 0000000..4b1d344 --- /dev/null +++ b/.gitea/workflows/checks.yaml @@ -0,0 +1,31 @@ +name: "Code Checks" +on: + push: + pull_request: + +jobs: + # Check formatting with rustfmt + formatting: + name: cargo fmt + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + # Ensure rustfmt is installed and setup problem matcher + - uses: actions-rust-lang/setup-rust-toolchain@v1 + with: + components: rustfmt + - name: Rustfmt Check + uses: actions-rust-lang/rustfmt@v1 + + # Check code with clippy + clippy: + name: cargo clippy + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + # Ensure clippy is installed and setup problem matcher + - uses: actions-rust-lang/setup-rust-toolchain@v1 + with: + components: clippy + - name: Clippy + uses: actions-rust-lang/clippy@v1 \ No newline at end of file diff --git a/.gitea/workflows/tests.yaml b/.gitea/workflows/tests.yaml new file mode 100644 index 0000000..132d084 --- /dev/null +++ b/.gitea/workflows/tests.yaml @@ -0,0 +1,13 @@ +name: "Test Suite" +on: + push: + pull_request: + +jobs: + test: + name: cargo test + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions-rust-lang/setup-rust-toolchain@v1 + - run: cargo test --all-features