mirror of
https://github.com/rtic-rs/rtic.git
synced 2024-11-23 12:12:50 +01:00
Tests should always deny warnings
This commit is contained in:
parent
0ee2d2c2db
commit
e4b673646a
2 changed files with 8 additions and 12 deletions
|
@ -94,11 +94,7 @@ impl Package {
|
|||
pub struct TestMetadata {}
|
||||
|
||||
impl TestMetadata {
|
||||
pub fn match_package(
|
||||
deny_warnings: bool,
|
||||
package: Package,
|
||||
backend: Backends,
|
||||
) -> CargoCommand<'static> {
|
||||
pub fn match_package(package: Package, backend: Backends) -> CargoCommand<'static> {
|
||||
match package {
|
||||
Package::Rtic => {
|
||||
let features = format!(
|
||||
|
@ -111,38 +107,38 @@ impl TestMetadata {
|
|||
package: Some(package.name()),
|
||||
features,
|
||||
test: Some("ui".to_owned()),
|
||||
deny_warnings,
|
||||
deny_warnings: true,
|
||||
}
|
||||
}
|
||||
Package::RticMacros => CargoCommand::Test {
|
||||
package: Some(package.name()),
|
||||
features: Some(backend.to_rtic_macros_feature().to_owned()),
|
||||
test: None,
|
||||
deny_warnings,
|
||||
deny_warnings: true,
|
||||
},
|
||||
Package::RticSync => CargoCommand::Test {
|
||||
package: Some(package.name()),
|
||||
features: Some("testing".to_owned()),
|
||||
test: None,
|
||||
deny_warnings,
|
||||
deny_warnings: true,
|
||||
},
|
||||
Package::RticCommon => CargoCommand::Test {
|
||||
package: Some(package.name()),
|
||||
features: Some("testing".to_owned()),
|
||||
test: None,
|
||||
deny_warnings,
|
||||
deny_warnings: true,
|
||||
},
|
||||
Package::RticMonotonics => CargoCommand::Test {
|
||||
package: Some(package.name()),
|
||||
features: None,
|
||||
test: None,
|
||||
deny_warnings,
|
||||
deny_warnings: true,
|
||||
},
|
||||
Package::RticTime => CargoCommand::Test {
|
||||
package: Some(package.name()),
|
||||
features: Some("critical-section/std".into()),
|
||||
test: None,
|
||||
deny_warnings,
|
||||
deny_warnings: true,
|
||||
},
|
||||
}
|
||||
}
|
||||
|
|
|
@ -345,7 +345,7 @@ pub fn cargo_test<'c>(
|
|||
package
|
||||
.packages()
|
||||
.map(|p| {
|
||||
let meta = TestMetadata::match_package(globals.deny_warnings, p, backend);
|
||||
let meta = TestMetadata::match_package(p, backend);
|
||||
(globals, meta, false)
|
||||
})
|
||||
.run_and_coalesce()
|
||||
|
|
Loading…
Reference in a new issue