Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/insanity-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Insanity Check

on:
pull_request:
workflow_dispatch:

jobs:
clippy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
components: clippy

- name: Cache Rust build state
uses: Swatinem/rust-cache@v2

- name: Run clippy through Makefile
run: make check
26 changes: 26 additions & 0 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Integration Tests

on:
pull_request:
workflow_dispatch:

jobs:
integration:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
components: clippy

- name: Install cargo-nextest
uses: taiki-e/install-action@nextest

- name: Cache Rust build state
uses: Swatinem/rust-cache@v2

- name: Run integration tests
run: make test-integration
21 changes: 21 additions & 0 deletions .github/workflows/it-is-alive.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: It is alive!

on:
pull_request:
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install Rust
uses: dtolnay/rust-toolchain@stable

- name: Cache Rust build state
uses: Swatinem/rust-cache@v2

- name: Build release binaries
run: make
26 changes: 26 additions & 0 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Unit Tests

on:
pull_request:
workflow_dispatch:

jobs:
unit:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
components: clippy

- name: Install cargo-nextest
uses: taiki-e/install-action@nextest

- name: Cache Rust build state
uses: Swatinem/rust-cache@v2

- name: Run unit tests
run: make test-unit
11 changes: 10 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.PHONY: build dev devel check fix test test-all test-integration setup clean stats arm-devel arm x86-devel x86 setup-arm setup-x86 demo man
.PHONY: build dev devel check fix test test-unit test-all test-integration setup clean stats arm-devel arm x86-devel x86 setup-arm setup-x86 demo man

DEFAULT_TARGET := build
ARM_TARGET ?= aarch64-unknown-linux-musl
Expand Down Expand Up @@ -27,6 +27,15 @@ test: setup
cargo test $(CORE_WORKSPACE); \
fi

test-unit: setup
@if command -v cargo-nextest >/dev/null 2>&1; then \
cargo nextest run -p logjet --lib -p logjetd --bins; \
else \
echo "cargo-nextest not available, falling back to cargo test unit-only targets"; \
cargo test -p logjet --lib; \
cargo test -p logjetd --bin logjetd; \
fi

test-integration: setup
@if command -v cargo-nextest >/dev/null 2>&1; then \
cargo nextest run -p logjetd --test bridge_flows; \
Expand Down