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
99 changes: 67 additions & 32 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,23 +30,29 @@ jobs:
uses: actions/checkout@v7

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.toolchain }}
components: clippy, rustfmt
rustflags: ""
cache-shared-key: linux-quality
cache-save-if: ${{ github.ref == 'refs/heads/main' }}
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
with:
shared-key: linux-quality
cache-targets: true
cache-all-crates: false
cache-workspace-crates: false
cache-bin: false
save-if: ${{ github.ref == 'refs/heads/main' }}
cache-on-failure: false

- name: Check formatting
run: cargo fmt --all -- --check

- name: Run Clippy
run: cargo clippy --workspace --all-targets --all-features -- -D warnings
run: cargo clippy --locked --workspace --all-targets --all-features -- -D warnings

- name: Run tests
run: cargo test --workspace --all-targets --all-features
run: cargo test --locked --workspace --all-targets --all-features

lpp-client-integration:
name: LPP client integration (#142, #139)
Expand All @@ -56,12 +62,18 @@ jobs:
uses: actions/checkout@v7

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
rustflags: ""
cache-shared-key: linux-quality
cache-save-if: false
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
with:
shared-key: linux-quality
cache-targets: true
cache-all-crates: false
cache-workspace-crates: false
cache-bin: false
save-if: false
cache-on-failure: false

# The mock provider is built from the pinned language-provider-protocol
Expand All @@ -75,7 +87,7 @@ jobs:
path: language-provider-protocol

- name: Build the pinned LPP mock provider
run: cargo build -p lpp-mock-provider
run: cargo build --locked -p lpp-mock-provider
working-directory: language-provider-protocol

# REQUIRED: these suites self-skip when LPP_MOCK_PROVIDER is absent,
Expand All @@ -84,9 +96,9 @@ jobs:
env:
LPP_MOCK_PROVIDER: ${{ github.workspace }}/language-provider-protocol/target/debug/lpp-mock-provider
run: |
cargo test -p wright-lpp --test mock_provider
cargo test -p wright-driver --test lpp
cargo test -p wright-driver --test provider_edit
cargo test --locked -p wright-lpp --test mock_provider
cargo test --locked -p wright-driver --test lpp
cargo test --locked -p wright-driver --test provider_edit

v1-gates:
name: v1 release gates (N-level, scenarios, benchmarks)
Expand All @@ -96,12 +108,18 @@ jobs:
uses: actions/checkout@v7

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
rustflags: ""
cache-shared-key: linux-quality
cache-save-if: false
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
with:
shared-key: linux-quality
cache-targets: true
cache-all-crates: false
cache-workspace-crates: false
cache-bin: false
save-if: false
cache-on-failure: false

- name: Build wright (debug)
Expand Down Expand Up @@ -175,16 +193,22 @@ jobs:
uses: actions/checkout@v7

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
rustflags: ""
cache-shared-key: linux-quality
cache-save-if: false
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
with:
shared-key: linux-quality
cache-targets: true
cache-all-crates: false
cache-workspace-crates: false
cache-bin: false
save-if: false
cache-on-failure: false

- name: Run OSTW forward-compilation differential suite
run: cargo test -p wright-ostw --test differential
run: cargo test --locked -p wright-ostw --test differential

- name: Upload differential report
if: always()
Expand Down Expand Up @@ -228,16 +252,22 @@ jobs:
uses: actions/checkout@v7

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
rustflags: ""
cache-shared-key: linux-quality
cache-save-if: false
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
with:
shared-key: linux-quality
cache-targets: true
cache-all-crates: false
cache-workspace-crates: false
cache-bin: false
save-if: false
cache-on-failure: false

- name: Run native-vs-reference differential suite
run: cargo test -p wright-opy --test differential
run: cargo test --locked -p wright-opy --test differential

- name: Upload differential report
if: always()
Expand Down Expand Up @@ -266,13 +296,18 @@ jobs:
python-version: "3.12"

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
rustflags: ""
- name: Restore Rust cache
uses: Swatinem/rust-cache@v2
with:
shared-key: dist-validation-${{ runner.os }}
cache-targets: false
cache-all-crates: false
cache-workspace-crates: false
cache-bin: false
cache-save-if: ${{ github.ref == 'refs/heads/main' }}
save-if: ${{ github.ref == 'refs/heads/main' }}
cache-on-failure: false

- name: Set up Node.js
Expand All @@ -281,7 +316,7 @@ jobs:
node-version: 22

- name: Build wright CLI and LSP
run: cargo build -p wright-cli -p wright-lsp
run: cargo build --locked -p wright-cli -p wright-lsp

- name: Validate package-manager metadata and install script
run: python scripts/verify-dist.py
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/release-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,9 @@ jobs:
fetch-depth: 0

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
rustflags: ""
cache: false

- name: Update version, commit, and push the tag
id: tag
Expand Down
10 changes: 3 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,10 @@ jobs:
ref: ${{ env.RELEASE_TAG }}

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
components: clippy, rustfmt
rustflags: ""
cache: false

- name: Verify tag version matches the workspace implementation version
run: |
Expand Down Expand Up @@ -96,17 +94,15 @@ jobs:
ref: ${{ env.RELEASE_TAG }}

- name: Install Rust toolchain
uses: actions-rust-lang/setup-rust-toolchain@v1
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
rustflags: ""
cache: false

- name: Add cross-compile target
run: rustup target add "$TARGET"

- name: Build release binaries
run: cargo build --release -p wright-cli -p wright-lsp --target "$TARGET"
run: cargo build --locked --release -p wright-cli -p wright-lsp --target "$TARGET"

- name: Package archive with version stamp
run: |
Expand Down
Loading