Skip to content
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

Ignore should_panic tests on android #58900

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions src/bootstrap/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -650,6 +650,22 @@ impl Config {
let default = config.channel == "dev";
config.ignore_git = ignore_git.unwrap_or(default);

// Disable should_panic tests on Android targets. Panic in tests currently means a potential
// segfault could occur on Android, which will spuriously fail our CI.
//
// See #55861 for more information.
if config.targets.iter().any(|target| target.contains("android")) {
if let Subcommand::Test { test_args, .. } |
Subcommand::Bench { test_args, .. } = &mut config.cmd {
if !test_args.contains(&String::from("-Zunstable-options")) {
test_args.push(String::from("-Zunstable-options"));
}
if !test_args.contains(&String::from("--exclude-should-panic")) {
test_args.push(String::from("--exclude-should-panic"));
}
}
}

config
}

Expand Down