Fix broken tests
Signed-off-by: hi-rustin <rustin.liu@gmail.com>
This commit is contained in:
parent
878eff1207
commit
7cab8f7862
@ -181,8 +181,6 @@ fn profile_user_dist() {
|
|||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn rust_optimize() {
|
fn rust_optimize() {
|
||||||
let parse = |s| Config::parse_inner(&["check".to_owned()], |&_| toml::from_str(s).unwrap());
|
|
||||||
|
|
||||||
assert_eq!(parse("").rust_optimize.is_release(), true);
|
assert_eq!(parse("").rust_optimize.is_release(), true);
|
||||||
assert_eq!(parse("rust.optimize = false").rust_optimize.is_release(), false);
|
assert_eq!(parse("rust.optimize = false").rust_optimize.is_release(), false);
|
||||||
assert_eq!(parse("rust.optimize = true").rust_optimize.is_release(), true);
|
assert_eq!(parse("rust.optimize = true").rust_optimize.is_release(), true);
|
||||||
@ -193,7 +191,5 @@ fn rust_optimize() {
|
|||||||
#[test]
|
#[test]
|
||||||
#[should_panic]
|
#[should_panic]
|
||||||
fn invalid_rust_optimize() {
|
fn invalid_rust_optimize() {
|
||||||
Config::parse_inner(&["check".to_owned()], |&_| {
|
parse("rust.optimize = \"a\"");
|
||||||
toml::from_str("rust.optimize = \"a\"").unwrap()
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user