|
73 | 73 | # Run test in isolation, single-threaded to improve determinism |
74 | 74 | cargo test -p dash-spv --all-features -- --nocapture --test-threads=1 "$t" 2>&1 | tee -a segv_scan.log |
75 | 75 | rc=${PIPESTATUS[0]} |
76 | | - if [ $rc -ne 0 ]; then |
| 76 | + if [ "$rc" -ne 0 ]; then |
77 | 77 | if tail -n 200 segv_scan.log | grep -qE 'SIGSEGV|signal: 11'; then |
78 | 78 | FOUND_THIS_ATTEMPT+=("$t") |
79 | 79 | SEGV_TESTS+=("$t") |
@@ -176,139 +176,6 @@ jobs: |
176 | 176 | - name: Run script-based tests |
177 | 177 | run: ./contrib/test.sh |
178 | 178 |
|
179 | | - clippy: |
180 | | - name: Clippy (Non-strict) |
181 | | - runs-on: ubuntu-22.04-arm |
182 | | - steps: |
183 | | - - name: Checkout Crate |
184 | | - uses: actions/checkout@v4 |
185 | | - - name: Setup Rust toolchain |
186 | | - uses: dtolnay/rust-toolchain@stable |
187 | | - with: |
188 | | - components: clippy |
189 | | - - name: Run clippy (excluding strict-checked crates) |
190 | | - run: | |
191 | | - # Auto-discover all workspace crates and exclude strict-checked ones |
192 | | - STRICT_CRATES=("key-wallet" "key-wallet-manager" "key-wallet-ffi" "dashcore_hashes" "dashcore" "dash-spv" "dash-spv-ffi") |
193 | | - mapfile -t ALL_CRATES < <(cargo metadata --no-deps --format-version=1 | jq -r '.packages[].name' | sort -u) |
194 | | - for crate in "${ALL_CRATES[@]}"; do |
195 | | - if printf '%s\n' "${STRICT_CRATES[@]}" | grep -qx "$crate"; then |
196 | | - continue |
197 | | - fi |
198 | | - echo "Checking $crate (warnings allowed, errors will fail)..." |
199 | | - cargo clippy -p "$crate" --all-features --all-targets -- -W warnings |
200 | | - done |
201 | | -
|
202 | | - strict-checks: |
203 | | - name: Strict Warnings and Clippy Checks |
204 | | - runs-on: ubuntu-22.04-arm |
205 | | - steps: |
206 | | - - name: Checkout Crate |
207 | | - uses: actions/checkout@v4 |
208 | | - - name: Setup Rust toolchain |
209 | | - uses: dtolnay/rust-toolchain@stable |
210 | | - with: |
211 | | - components: clippy |
212 | | - - name: Cache cargo dependencies |
213 | | - uses: Swatinem/rust-cache@v2 |
214 | | - |
215 | | - # Check key-wallet with strict warnings |
216 | | - - name: Check key-wallet (deny warnings) |
217 | | - env: |
218 | | - RUSTFLAGS: "-D warnings" |
219 | | - run: | |
220 | | - cargo check -p key-wallet --all-features --lib --bins --tests |
221 | | - cargo build -p key-wallet --all-features --lib --bins |
222 | | - cargo test -p key-wallet --all-features --lib --bins |
223 | | -
|
224 | | - - name: Clippy key-wallet (deny all warnings) |
225 | | - run: cargo clippy -p key-wallet --all-features --lib --bins --tests -- -D warnings |
226 | | - |
227 | | - # Check key-wallet-manager with strict warnings |
228 | | - - name: Check key-wallet-manager (deny warnings) |
229 | | - env: |
230 | | - RUSTFLAGS: "-D warnings" |
231 | | - run: | |
232 | | - cargo check -p key-wallet-manager --all-features --lib --bins --tests |
233 | | - cargo build -p key-wallet-manager --all-features --lib --bins |
234 | | - cargo test -p key-wallet-manager --all-features --lib --bins |
235 | | -
|
236 | | - - name: Clippy key-wallet-manager (deny all warnings) |
237 | | - run: cargo clippy -p key-wallet-manager --all-features --lib --bins --tests -- -D warnings |
238 | | - |
239 | | - # Check key-wallet-ffi with strict warnings |
240 | | - - name: Check key-wallet-ffi (deny warnings) |
241 | | - env: |
242 | | - RUSTFLAGS: "-D warnings" |
243 | | - run: | |
244 | | - cargo check -p key-wallet-ffi --all-features --lib --bins --tests |
245 | | - cargo build -p key-wallet-ffi --all-features --lib --bins |
246 | | - cargo test -p key-wallet-ffi --all-features --lib --bins |
247 | | -
|
248 | | - - name: Clippy key-wallet-ffi (deny all warnings) |
249 | | - run: cargo clippy -p key-wallet-ffi --all-features --lib --bins --tests -- -D warnings |
250 | | - |
251 | | - # Check dashcore with strict warnings |
252 | | - - name: Check dashcore (deny warnings) |
253 | | - env: |
254 | | - RUSTFLAGS: "-D warnings" |
255 | | - run: | |
256 | | - cargo check -p dashcore --all-features --lib --bins --tests |
257 | | - cargo build -p dashcore --all-features --lib --bins |
258 | | - cargo test -p dashcore --all-features --lib --bins |
259 | | -
|
260 | | - - name: Clippy dashcore (deny all warnings) |
261 | | - run: cargo clippy -p dashcore --all-features --lib --bins --tests -- -D warnings |
262 | | - |
263 | | - # Check dashcore_hashes with strict warnings |
264 | | - - name: Check dashcore_hashes (deny warnings) |
265 | | - env: |
266 | | - RUSTFLAGS: "-D warnings" |
267 | | - run: | |
268 | | - cargo check -p dashcore_hashes --all-features --lib --bins --tests |
269 | | - cargo build -p dashcore_hashes --all-features --lib --bins |
270 | | - cargo test -p dashcore_hashes --all-features --lib --bins |
271 | | -
|
272 | | - - name: Clippy dashcore_hashes (deny all warnings) |
273 | | - run: cargo clippy -p dashcore_hashes --all-features --lib --bins --tests -- -D warnings |
274 | | - |
275 | | - # Check dash-spv with strict warnings |
276 | | - - name: Check dash-spv (deny warnings) |
277 | | - env: |
278 | | - RUSTFLAGS: "-D warnings" |
279 | | - run: | |
280 | | - cargo check -p dash-spv --all-features --lib --bins --tests |
281 | | - cargo build -p dash-spv --all-features --lib --bins |
282 | | - cargo test -p dash-spv --all-features --lib --bins |
283 | | -
|
284 | | - - name: Clippy dash-spv (deny all warnings) |
285 | | - run: cargo clippy -p dash-spv --all-features --lib --bins --tests -- -D warnings |
286 | | - |
287 | | - # Check dash-spv-ffi with strict warnings |
288 | | - - name: Check dash-spv-ffi (deny warnings) |
289 | | - env: |
290 | | - RUSTFLAGS: "-D warnings" |
291 | | - run: | |
292 | | - cargo check -p dash-spv-ffi --all-features --lib --bins --tests |
293 | | - cargo build -p dash-spv-ffi --all-features --lib --bins |
294 | | - cargo test -p dash-spv-ffi --all-features --lib --bins |
295 | | -
|
296 | | - - name: Clippy dash-spv-ffi (deny all warnings) |
297 | | - run: cargo clippy -p dash-spv-ffi --all-features --lib --bins --tests -- -D warnings |
298 | | - |
299 | | - fmt: |
300 | | - name: Format |
301 | | - runs-on: ubuntu-22.04-arm |
302 | | - steps: |
303 | | - - name: Checkout Crate |
304 | | - uses: actions/checkout@v4 |
305 | | - - name: Setup Rust toolchain |
306 | | - uses: dtolnay/rust-toolchain@stable |
307 | | - with: |
308 | | - components: rustfmt |
309 | | - - name: Check formatting |
310 | | - run: cargo fmt --all -- --check |
311 | | - |
312 | 179 | rpc_tests: |
313 | 180 | name: RPC Tests |
314 | 181 | runs-on: ubuntu-22.04-arm |
@@ -344,16 +211,3 @@ jobs: |
344 | 211 | env: |
345 | 212 | DASHVERSION: ${{ matrix.dashversion }} |
346 | 213 | run: ./contrib/test-rpc.sh |
347 | | - |
348 | | - actionlint: |
349 | | - name: Lint GitHub Actions |
350 | | - runs-on: ubuntu-22.04-arm |
351 | | - permissions: |
352 | | - contents: read |
353 | | - steps: |
354 | | - - name: Checkout Crate |
355 | | - uses: actions/checkout@v4 |
356 | | - - name: Run actionlint |
357 | | - uses: reviewdog/action-actionlint@v1 |
358 | | - with: |
359 | | - fail_on_error: true |
0 commit comments