-
Notifications
You must be signed in to change notification settings - Fork 13k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
x.py ignores config.toml's debug-assertions-std for unit tests #79481
Comments
@ssomers I can't reproduce. I added this assert: diff --git a/library/core/tests/iter/traits/iterator.rs b/library/core/tests/iter/traits/iterator.rs
index 422e389e380..77e1effc764 100644
--- a/library/core/tests/iter/traits/iterator.rs
+++ b/library/core/tests/iter/traits/iterator.rs
@@ -26,6 +26,7 @@ fn cmp(&self, other: &Self) -> core::cmp::Ordering {
#[test]
fn test_lt() {
+ debug_assert!(false);
let empty: [isize; 0] = [];
let xs = [1, 2, 3];
let ys = [1, 2, 0];
and set Are you expecting assertions to run in |
Not exactly sure what I was doing back then, nor what you mean with running in coretests. Today, I'd expect, for instance when #[test]
fn test_assert() {
assert!(false)
}
#[test]
fn test_debug_assert() {
debug_assert!(false)
} and running |
@ssomers I'm still not able to replicate this. I ran
|
Well, I can still replicate it… on the master at the time. I located the fix at auto merge #90042 (25 October). And it's really flawless now. The debug assertions detonate if |
If you have in your config.toml file (or whichever file --config says), only this change to config.toml.example:
debug assertions in src/liballoc or library/alloc used to be armed. Since #73374, debug assertions only go off if you also turn on
debug
. EDIT: since some point, even that doesn't help.The text was updated successfully, but these errors were encountered: