Skip to content

Commit

Permalink
ci: pass -Zdoctest-xcompile to cargo test to run doctests
Browse files Browse the repository at this point in the history
By default, cargo test does not run doctests when the target triple does
not match the host triple. There are some valid reasons for that to be
the case, but we didn't notice until now because no warnings were
outputted: the doctests were just silently skipped.

Let's use unstable Rust features to run those tests as originally
intended.

Related tracking issue: rust-lang/rust#64245
  • Loading branch information
AlexTMjugador committed Feb 8, 2023
1 parent 013e546 commit aab3080
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -104,4 +104,5 @@ jobs:
# Handle AArch64 dynamic libraries installed by libc6-arm64-cross
# being in a path that the dynamic linker does not check by default
LD_LIBRARY_PATH: /usr/aarch64-linux-gnu/lib
run: cargo test --release --target ${{ matrix.target }} ${{ matrix.packages-to-test }} -- --nocapture
run: cargo test --release --target ${{ matrix.target }} -Zdoctest-xcompile
${{ matrix.packages-to-test }} -- --nocapture

0 comments on commit aab3080

Please sign in to comment.