We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3e9d487 commit 75e817fCopy full SHA for 75e817f
src/lib.rs
@@ -144,15 +144,17 @@ mod tests {
144
assert!(works5());
145
}
146
147
- extern crate std;
148
#[test]
+ #[allow(clippy::assertions_on_constants)]
149
fn test_usage_within_a_function() {
150
cfg_if! {if #[cfg(debug_assertions)] {
151
- std::println!("debug");
152
- std::println!("debug2");
+ // we want to put more than one thing here to make sure that they
+ // all get configured properly.
153
+ assert!(cfg!(debug_assertions));
154
+ assert_eq!(4, 2+2);
155
} else {
- std::println!("release");
- std::println!("release2");
156
+ assert!(works1().is_some());
157
+ assert_eq!(10, 5+5);
158
}}
159
160
0 commit comments