Skip to content

Commit c96421e

Browse files
committed
ci: run intern tests via cargo miri
1 parent 3ed13b4 commit c96421e

File tree

2 files changed

+21
-2
lines changed

2 files changed

+21
-2
lines changed

Diff for: .github/workflows/ci.yaml

+21-1
Original file line numberDiff line numberDiff line change
@@ -143,13 +143,33 @@ jobs:
143143
run: target/${{ matrix.target }}/debug/rust-analyzer analysis-stats --with-deps --no-sysroot --no-test $(rustc --print sysroot)/lib/rustlib/src/rust/library/
144144

145145
- name: clippy
146-
if: matrix.os == 'windows-latest'
146+
if: matrix.os == 'macos-latest'
147147
run: cargo clippy --all-targets -- -D clippy::disallowed_macros -D clippy::dbg_macro -D clippy::todo -D clippy::print_stdout -D clippy::print_stderr
148148

149149
- name: rustfmt
150150
if: matrix.os == 'ubuntu-latest'
151151
run: cargo fmt -- --check
152152

153+
# Weird targets to catch non-portable code
154+
miri:
155+
if: github.repository == 'rust-lang/rust-analyzer'
156+
name: miri
157+
runs-on: ubuntu-latest
158+
159+
steps:
160+
- name: Checkout repository
161+
uses: actions/checkout@v4
162+
163+
- name: Install Rust toolchain
164+
run: |
165+
rustup update --no-self-update nightly
166+
rustup component add miri --toolchain nightly
167+
168+
- name: Cache Dependencies
169+
uses: Swatinem/rust-cache@9bdad043e88c75890e36ad3bbc8d27f0090dd609
170+
171+
- run: cargo +nightly miri test --locked
172+
153173
# Weird targets to catch non-portable code
154174
rust-cross:
155175
if: github.repository == 'rust-lang/rust-analyzer'

Diff for: crates/intern/Cargo.toml

-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ rust-version.workspace = true
1313

1414

1515
[dependencies]
16-
# We need to freeze the version of the crate, as the raw-api feature is considered unstable
1716
dashmap.workspace = true
1817
hashbrown.workspace = true
1918
rustc-hash.workspace = true

0 commit comments

Comments
 (0)