From 8157a3f0afe978d3e953420577f8344db7e905bf Mon Sep 17 00:00:00 2001 From: Caleb Cartwright Date: Tue, 29 Oct 2019 13:35:12 -0500 Subject: [PATCH] tests: fix system tests on non-nightly --- src/config/mod.rs | 3 +++ tests/config/issue-3779.toml | 1 - tests/source/issue-3779/lib.rs | 1 + tests/target/issue-3779/lib.rs | 1 + 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/config/mod.rs b/src/config/mod.rs index cf00eed0565..07c5612e26e 100644 --- a/src/config/mod.rs +++ b/src/config/mod.rs @@ -481,6 +481,9 @@ mod test { #[test] fn test_valid_license_template_path() { + if !crate::is_nightly_channel!() { + return; + } let toml = r#"license_template_path = "tests/license-template/lt.txt""#; let config = Config::from_toml(toml, Path::new("")).unwrap(); assert!(config.license_template.is_some()); diff --git a/tests/config/issue-3779.toml b/tests/config/issue-3779.toml index 83505f409af..6ca52aee322 100644 --- a/tests/config/issue-3779.toml +++ b/tests/config/issue-3779.toml @@ -1,4 +1,3 @@ -unstable_features = true ignore = [ "tests/**/issue-3779/ice.rs" ] diff --git a/tests/source/issue-3779/lib.rs b/tests/source/issue-3779/lib.rs index d7c2ae28975..16e9d48337b 100644 --- a/tests/source/issue-3779/lib.rs +++ b/tests/source/issue-3779/lib.rs @@ -1,3 +1,4 @@ +// rustfmt-unstable: true // rustfmt-config: issue-3779.toml #[path = "ice.rs"] diff --git a/tests/target/issue-3779/lib.rs b/tests/target/issue-3779/lib.rs index ebebce417d1..a5673a4db7e 100644 --- a/tests/target/issue-3779/lib.rs +++ b/tests/target/issue-3779/lib.rs @@ -1,3 +1,4 @@ +// rustfmt-unstable: true // rustfmt-config: issue-3779.toml #[path = "ice.rs"]