Skip to content

Commit d8c8548

Browse files
committed
Auto merge of #8713 - ehuss:filters_target-cross, r=alexcrichton
Add cross check to filters_target test. This test requires a cross compiler target to be installed, so disable it if it is not.
2 parents e4b65bd + 8ee908d commit d8c8548

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

tests/testsuite/tree.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//! Tests for the `cargo tree` command.
22
3-
use cargo_test_support::cross_compile::alternate;
3+
use cargo_test_support::cross_compile::{self, alternate};
44
use cargo_test_support::registry::{Dependency, Package};
55
use cargo_test_support::{basic_manifest, git, project, rustc_host, Project};
66

@@ -324,6 +324,9 @@ a v0.1.0 ([..]/foo)
324324
#[cargo_test]
325325
fn filters_target() {
326326
// --target flag
327+
if cross_compile::disabled() {
328+
return;
329+
}
327330
Package::new("targetdep", "1.0.0").publish();
328331
Package::new("hostdep", "1.0.0").publish();
329332
Package::new("devdep", "1.0.0").publish();

0 commit comments

Comments
 (0)