Skip to content

Commit

Permalink
Use exec_env to set backtrace level and normalize output
Browse files Browse the repository at this point in the history
  • Loading branch information
phansch committed Oct 8, 2019
1 parent 04133ea commit 5dfb697
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions tests/ui/custom_ice_message.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// exec-env:RUST_BACKTRACE=0
// normalize-stderr-test: "Clippy version: .*" -> "Clippy version: foo"
// normalize-stderr-test: "internal_lints.rs.*" -> "internal_lints.rs:1:1"

#![deny(clippy::internal)]

fn should_trigger_an_ice_in_clippy() {}
Expand Down
4 changes: 2 additions & 2 deletions tests/ui/custom_ice_message.stderr
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
thread 'rustc' panicked at 'Testing the ICE message', clippy_lints/src/utils/internal_lints.rs:333:13
thread 'rustc' panicked at 'Testing the ICE message', clippy_lints/src/utils/internal_lints.rs:1:1
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.

error: internal compiler error: unexpected panic
Expand All @@ -7,5 +7,5 @@ note: the compiler unexpectedly panicked. this is a bug.

note: we would appreciate a bug report: https://github.com/rust-lang/rust-clippy/issues/new

note: Clippy version: clippy 0.0.212 (68ff8b19 2019-09-26)
note: Clippy version: foo

0 comments on commit 5dfb697

Please sign in to comment.