"libc 0.2.34 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
"miow 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
+ "regex 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.24 (registry+https://github.com/rust-lang/crates.io-index)",
"winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
]
// aux-build:changing-crates-a1.rs
// aux-build:changing-crates-b.rs
// aux-build:changing-crates-a2.rs
+// normalize-stderr-test: "(crate `(\w+)`:) .*" -> "$1 $$PATH_$2"
extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
error[E0460]: found possibly newer version of crate `a` which `b` depends on
- --> $DIR/changing-crates.rs:19:1
+ --> $DIR/changing-crates.rs:20:1
|
-19 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
+20 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
| ^^^^^^^^^^^^^^^
|
= note: perhaps that crate needs to be recompiled?
= note: the following crate versions were found:
- crate `a`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/changing-crates.stage1-x86_64-pc-windows-gnu.aux/a.dll
- crate `b`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/changing-crates.stage1-x86_64-pc-windows-gnu.aux/b.dll
+ crate `a`: $PATH_a
+ crate `b`: $PATH_b
error: aborting due to previous error
// aux-build:svh-a-base.rs
// aux-build:svh-b.rs
// aux-build:svh-a-change-lit.rs
+// normalize-stderr-test: "(crate `(\w+)`:) .*" -> "$1 $$PATH_$2"
extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
error[E0460]: found possibly newer version of crate `a` which `b` depends on
- --> $DIR/svh-change-lit.rs:19:1
+ --> $DIR/svh-change-lit.rs:20:1
|
-19 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
+20 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
| ^^^^^^^^^^^^^^^
|
= note: perhaps that crate needs to be recompiled?
= note: the following crate versions were found:
- crate `a`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-lit.stage1-x86_64-pc-windows-gnu.aux/a.dll
- crate `b`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-lit.stage1-x86_64-pc-windows-gnu.aux/b.dll
+ crate `a`: $PATH_a
+ crate `b`: $PATH_b
error: aborting due to previous error
// aux-build:svh-a-base.rs
// aux-build:svh-b.rs
// aux-build:svh-a-change-significant-cfg.rs
+// normalize-stderr-test: "(crate `(\w+)`:) .*" -> "$1 $$PATH_$2"
extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
error[E0460]: found possibly newer version of crate `a` which `b` depends on
- --> $DIR/svh-change-significant-cfg.rs:19:1
+ --> $DIR/svh-change-significant-cfg.rs:20:1
|
-19 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
+20 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
| ^^^^^^^^^^^^^^^
|
= note: perhaps that crate needs to be recompiled?
= note: the following crate versions were found:
- crate `a`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-significant-cfg.stage1-x86_64-pc-windows-gnu.aux/a.dll
- crate `b`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-significant-cfg.stage1-x86_64-pc-windows-gnu.aux/b.dll
+ crate `a`: $PATH_a
+ crate `b`: $PATH_b
error: aborting due to previous error
// aux-build:svh-a-base.rs
// aux-build:svh-b.rs
// aux-build:svh-a-change-trait-bound.rs
+// normalize-stderr-test: "(crate `(\w+)`:) .*" -> "$1 $$PATH_$2"
extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
error[E0460]: found possibly newer version of crate `a` which `b` depends on
- --> $DIR/svh-change-trait-bound.rs:19:1
+ --> $DIR/svh-change-trait-bound.rs:20:1
|
-19 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
+20 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
| ^^^^^^^^^^^^^^^
|
= note: perhaps that crate needs to be recompiled?
= note: the following crate versions were found:
- crate `a`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-trait-bound.stage1-x86_64-pc-windows-gnu.aux/a.dll
- crate `b`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-trait-bound.stage1-x86_64-pc-windows-gnu.aux/b.dll
+ crate `a`: $PATH_a
+ crate `b`: $PATH_b
error: aborting due to previous error
// aux-build:svh-a-base.rs
// aux-build:svh-b.rs
// aux-build:svh-a-change-type-arg.rs
+// normalize-stderr-test: "(crate `(\w+)`:) .*" -> "$1 $$PATH_$2"
extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
error[E0460]: found possibly newer version of crate `a` which `b` depends on
- --> $DIR/svh-change-type-arg.rs:19:1
+ --> $DIR/svh-change-type-arg.rs:20:1
|
-19 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
+20 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
| ^^^^^^^^^^^^^^^
|
= note: perhaps that crate needs to be recompiled?
= note: the following crate versions were found:
- crate `a`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-type-arg.stage1-x86_64-pc-windows-gnu.aux/a.dll
- crate `b`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-type-arg.stage1-x86_64-pc-windows-gnu.aux/b.dll
+ crate `a`: $PATH_a
+ crate `b`: $PATH_b
error: aborting due to previous error
// aux-build:svh-a-base.rs
// aux-build:svh-b.rs
// aux-build:svh-a-change-type-ret.rs
+// normalize-stderr-test: "(crate `(\w+)`:) .*" -> "$1 $$PATH_$2"
extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
error[E0460]: found possibly newer version of crate `a` which `b` depends on
- --> $DIR/svh-change-type-ret.rs:19:1
+ --> $DIR/svh-change-type-ret.rs:20:1
|
-19 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
+20 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
| ^^^^^^^^^^^^^^^
|
= note: perhaps that crate needs to be recompiled?
= note: the following crate versions were found:
- crate `a`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-type-ret.stage1-x86_64-pc-windows-gnu.aux/a.dll
- crate `b`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-type-ret.stage1-x86_64-pc-windows-gnu.aux/b.dll
+ crate `a`: $PATH_a
+ crate `b`: $PATH_b
error: aborting due to previous error
// aux-build:svh-a-base.rs
// aux-build:svh-b.rs
// aux-build:svh-a-change-type-static.rs
+// normalize-stderr-test: "(crate `(\w+)`:) .*" -> "$1 $$PATH_$2"
extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
error[E0460]: found possibly newer version of crate `a` which `b` depends on
- --> $DIR/svh-change-type-static.rs:19:1
+ --> $DIR/svh-change-type-static.rs:20:1
|
-19 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
+20 | extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
| ^^^^^^^^^^^^^^^
|
= note: perhaps that crate needs to be recompiled?
= note: the following crate versions were found:
- crate `a`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-type-static.stage1-x86_64-pc-windows-gnu.aux/a.dll
- crate `b`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-change-type-static.stage1-x86_64-pc-windows-gnu.aux/b.dll
+ crate `a`: $PATH_a
+ crate `b`: $PATH_b
error: aborting due to previous error
// aux-build:svh-uta-base.rs
// aux-build:svh-utb.rs
// aux-build:svh-uta-change-use-trait.rs
+// normalize-stderr-test: "(crate `(\w+)`:) .*" -> "$1 $$PATH_$2"
//! "compile-fail/svh-uta-trait.rs" is checking that we detect a
//! change from `use foo::TraitB` to use `foo::TraitB` in the hash
error[E0460]: found possibly newer version of crate `uta` which `utb` depends on
- --> $DIR/svh-use-trait.rs:24:1
+ --> $DIR/svh-use-trait.rs:25:1
|
-24 | extern crate utb; //~ ERROR: found possibly newer version of crate `uta` which `utb` depends
+25 | extern crate utb; //~ ERROR: found possibly newer version of crate `uta` which `utb` depends
| ^^^^^^^^^^^^^^^^^
|
= note: perhaps that crate needs to be recompiled?
= note: the following crate versions were found:
- crate `uta`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-use-trait.stage1-x86_64-pc-windows-gnu.aux/uta.dll
- crate `utb`: /?/C:/msys64/home/we/rust/build/x86_64-pc-windows-gnu/test/ui/svh-use-trait.stage1-x86_64-pc-windows-gnu.aux/utb.dll
+ crate `uta`: $PATH_uta
+ crate `utb`: $PATH_utb
error: aborting due to previous error
// option. This file may not be copied, modified, or distributed
// except according to those terms.
-// normalize-stderr-32bit: "&str (64 bits)" -> "&str ($STR bits)"
-// normalize-stderr-64bit: "&str (128 bits)" -> "&str ($STR bits)"
+// normalize-stderr-32bit: "&str \(64 bits\)" -> "&str ($$STR bits)"
+// normalize-stderr-64bit: "&str \(128 bits\)" -> "&str ($$STR bits)"
filetime = "0.1"
getopts = "0.2"
log = "0.3"
+regex = "0.2"
rustc-serialize = "0.3"
[target.'cfg(unix)'.dependencies]
#[macro_use]
extern crate log;
extern crate rustc_serialize;
+extern crate regex;
extern crate test;
use std::env;
use header::TestProps;
use test::TestPaths;
use util::logv;
+use regex::Regex;
use std::collections::HashMap;
use std::collections::HashSet;
.replace("\r\n", "\n") // normalize for linebreaks on windows
.replace("\t", "\\t"); // makes tabs visible
for rule in custom_rules {
- normalized = normalized.replace(&rule.0, &rule.1);
+ let re = Regex::new(&rule.0).expect("bad regex in custom normalization rule");
+ normalized = re.replace_all(&normalized, &rule.1[..]).into_owned();
}
normalized
}