diff --git a/Cargo.toml b/Cargo.toml index 122b49f..11db88f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,5 +11,9 @@ owo-colors = "4.2.0" [profile.release] debug = 1 + [dev-dependencies] tempfile = "3.18.0" + +[lints.rust] +unexpected_cfgs = { level = "warn", check-cfg = ['cfg(slow_tests)'] } diff --git a/src/inst.rs b/src/inst.rs index ba5581e..82c16ed 100644 --- a/src/inst.rs +++ b/src/inst.rs @@ -1126,11 +1126,8 @@ mod tests { use std::io::Write; #[test] + #[cfg_attr(not(slow_tests), ignore)] fn exhaustive_decode_no_panic() { - if std::env::var("SLOW_TESTS").is_err() { - return; - } - for i in 0..u32::MAX { if (i % (2 << 25)) == 0 { let percent = i as f32 / (u32::MAX as f32);