mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-12-18 00:53:31 +00:00
Auto merge of #11225 - matthiaskrgr:fix_integration_tests2, r=flip1995
Fix integration tests #2 fix integration tests. It turned out that the following tests fail to build at all: chalk, combine, stdarch and hyper. This is often a problem of passing `--all-targets --all-features`, in case of combine though, outdated deps were to blame. I have opened tickets against combine and rustfmt https://github.com/rust-lang/rustfmt/issues/5859 https://github.com/Marwes/combine/issues/357 should we just remove the other failing repos? :/ changelog: fix integration tests on ci
This commit is contained in:
commit
fc13bf8be2
2 changed files with 18 additions and 14 deletions
28
.github/workflows/clippy_bors.yml
vendored
28
.github/workflows/clippy_bors.yml
vendored
|
@ -187,16 +187,14 @@ jobs:
|
|||
- name: Extract Binaries
|
||||
run: |
|
||||
DIR=$CARGO_TARGET_DIR/debug
|
||||
rm $DIR/deps/integration-*.d
|
||||
mv $DIR/deps/integration-* $DIR/integration
|
||||
find $DIR/deps/integration-* -executable ! -type d | xargs -I {} mv {} $DIR/integration
|
||||
find $DIR ! -executable -o -type d ! -path $DIR | xargs rm -rf
|
||||
rm -rf $CARGO_TARGET_DIR/release
|
||||
|
||||
- name: Upload Binaries
|
||||
uses: actions/upload-artifact@v1
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: target
|
||||
path: target
|
||||
name: binaries
|
||||
path: target/debug
|
||||
|
||||
integration:
|
||||
needs: integration_build
|
||||
|
@ -206,16 +204,13 @@ jobs:
|
|||
matrix:
|
||||
integration:
|
||||
- 'rust-lang/cargo'
|
||||
# FIXME: re-enable once fmt_macros is renamed in RLS
|
||||
# - 'rust-lang/rls'
|
||||
- 'rust-lang/chalk'
|
||||
- 'rust-lang/rustfmt'
|
||||
- 'Marwes/combine'
|
||||
- 'Geal/nom'
|
||||
- 'rust-lang/stdarch'
|
||||
- 'serde-rs/serde'
|
||||
# FIXME: chrono currently cannot be compiled with `--all-targets`
|
||||
# - 'chronotope/chrono'
|
||||
- 'chronotope/chrono'
|
||||
- 'hyperium/hyper'
|
||||
- 'rust-random/rand'
|
||||
- 'rust-lang/futures-rs'
|
||||
|
@ -237,12 +232,17 @@ jobs:
|
|||
- name: Install toolchain
|
||||
run: rustup show active-toolchain
|
||||
|
||||
- name: Set LD_LIBRARY_PATH
|
||||
run: |
|
||||
SYSROOT=$(rustc --print sysroot)
|
||||
echo "LD_LIBRARY_PATH=${SYSROOT}/lib${LD_LIBRARY_PATH+:${LD_LIBRARY_PATH}}" >> $GITHUB_ENV
|
||||
|
||||
# Download
|
||||
- name: Download target dir
|
||||
uses: actions/download-artifact@v1
|
||||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: target
|
||||
path: target
|
||||
name: binaries
|
||||
path: target/debug
|
||||
|
||||
- name: Make Binaries Executable
|
||||
run: chmod +x $CARGO_TARGET_DIR/debug/*
|
||||
|
@ -251,7 +251,7 @@ jobs:
|
|||
- name: Test ${{ matrix.integration }}
|
||||
run: |
|
||||
RUSTUP_TOOLCHAIN="$(rustup show active-toolchain | grep -o -E "nightly-[0-9]{4}-[0-9]{2}-[0-9]{2}")" \
|
||||
$CARGO_TARGET_DIR/debug/integration
|
||||
$CARGO_TARGET_DIR/debug/integration --show-output
|
||||
env:
|
||||
INTEGRATION: ${{ matrix.integration }}
|
||||
|
||||
|
|
|
@ -65,6 +65,10 @@ fn integration_test() {
|
|||
.expect("unable to run clippy");
|
||||
|
||||
let stderr = String::from_utf8_lossy(&output.stderr);
|
||||
|
||||
// debug:
|
||||
eprintln!("{stderr}");
|
||||
|
||||
if let Some(backtrace_start) = stderr.find("error: internal compiler error") {
|
||||
static BACKTRACE_END_MSG: &str = "end of query stack";
|
||||
let backtrace_end = stderr[backtrace_start..]
|
||||
|
|
Loading…
Reference in a new issue