Skip to content

Commit cbedd29

Browse files
committed
Auto merge of #5404 - matklad:remove-useless-nightly, r=matklad
Remove some `is_nightly` checks from tests
2 parents 8f3dd18 + 14067b9 commit cbedd29

File tree

4 files changed

+0
-78
lines changed

4 files changed

+0
-78
lines changed

tests/testsuite/build.rs

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,6 @@ fn cargo_fail_with_no_stderr() {
4747
/// `rustc` getting `-Zincremental` passed to it.
4848
#[test]
4949
fn cargo_compile_incremental() {
50-
if !is_nightly() {
51-
return;
52-
}
53-
5450
let p = project("foo")
5551
.file("Cargo.toml", &basic_bin_manifest("foo"))
5652
.file("src/foo.rs", &main_file(r#""i am foo""#, &[]))
@@ -77,10 +73,6 @@ fn cargo_compile_incremental() {
7773

7874
#[test]
7975
fn incremental_profile() {
80-
if !is_nightly() {
81-
return;
82-
}
83-
8476
let p = project("foo")
8577
.file(
8678
"Cargo.toml",
@@ -137,10 +129,6 @@ fn incremental_profile() {
137129

138130
#[test]
139131
fn incremental_config() {
140-
if !is_nightly() {
141-
return;
142-
}
143-
144132
let p = project("foo")
145133
.file(
146134
"Cargo.toml",
@@ -3682,31 +3670,6 @@ fn custom_target_dir() {
36823670
);
36833671
}
36843672

3685-
#[test]
3686-
fn rustc_no_trans() {
3687-
if !is_nightly() {
3688-
return;
3689-
}
3690-
3691-
let p = project("foo")
3692-
.file(
3693-
"Cargo.toml",
3694-
r#"
3695-
[package]
3696-
name = "foo"
3697-
version = "0.0.1"
3698-
authors = []
3699-
"#,
3700-
)
3701-
.file("src/main.rs", "fn main() {}")
3702-
.build();
3703-
3704-
assert_that(
3705-
p.cargo("rustc").arg("-v").arg("--").arg("-Zno-trans"),
3706-
execs().with_status(0),
3707-
);
3708-
}
3709-
37103673
#[test]
37113674
fn build_multiple_packages() {
37123675
let p = project("foo")

tests/testsuite/check.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
use cargotest::install::exe;
2-
use cargotest::is_nightly;
32
use cargotest::support::paths::CargoPathExt;
43
use cargotest::support::registry::Package;
54
use cargotest::support::{execs, project};
@@ -107,9 +106,6 @@ fn check_fail() {
107106

108107
#[test]
109108
fn custom_derive() {
110-
if !is_nightly() {
111-
return;
112-
}
113109
let foo = project("foo")
114110
.file(
115111
"Cargo.toml",
@@ -126,8 +122,6 @@ fn custom_derive() {
126122
.file(
127123
"src/main.rs",
128124
r#"
129-
#![feature(proc_macro)]
130-
131125
#[macro_use]
132126
extern crate bar;
133127
@@ -160,9 +154,6 @@ fn main() {
160154
.file(
161155
"src/lib.rs",
162156
r#"
163-
#![feature(proc_macro, proc_macro_lib)]
164-
#![crate_type = "proc-macro"]
165-
166157
extern crate proc_macro;
167158
168159
use proc_macro::TokenStream;

tests/testsuite/path.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ use std::fs::{self, File};
22
use std::io::prelude::*;
33

44
use cargo::util::process;
5-
use cargotest;
65
use cargotest::sleep_ms;
76
use cargotest::support::paths::{self, CargoPathExt};
87
use cargotest::support::{execs, main_file, project};
@@ -1284,9 +1283,6 @@ fn workspace_produces_rlib() {
12841283

12851284
#[test]
12861285
fn thin_lto_works() {
1287-
if !cargotest::is_nightly() {
1288-
return;
1289-
}
12901286
let p = project("foo")
12911287
.file(
12921288
"Cargo.toml",

tests/testsuite/proc_macro.rs

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@ use hamcrest::assert_that;
44

55
#[test]
66
fn probe_cfg_before_crate_type_discovery() {
7-
if !is_nightly() {
8-
return;
9-
}
10-
117
let client = project("client")
128
.file(
139
"Cargo.toml",
@@ -24,8 +20,6 @@ fn probe_cfg_before_crate_type_discovery() {
2420
.file(
2521
"src/main.rs",
2622
r#"
27-
#![feature(proc_macro)]
28-
2923
#[macro_use]
3024
extern crate noop;
3125
@@ -52,8 +46,6 @@ fn probe_cfg_before_crate_type_discovery() {
5246
.file(
5347
"src/lib.rs",
5448
r#"
55-
#![feature(proc_macro, proc_macro_lib)]
56-
5749
extern crate proc_macro;
5850
use proc_macro::TokenStream;
5951
@@ -70,10 +62,6 @@ fn probe_cfg_before_crate_type_discovery() {
7062

7163
#[test]
7264
fn noop() {
73-
if !is_nightly() {
74-
return;
75-
}
76-
7765
let client = project("client")
7866
.file(
7967
"Cargo.toml",
@@ -90,8 +78,6 @@ fn noop() {
9078
.file(
9179
"src/main.rs",
9280
r#"
93-
#![feature(proc_macro)]
94-
9581
#[macro_use]
9682
extern crate noop;
9783
@@ -118,8 +104,6 @@ fn noop() {
118104
.file(
119105
"src/lib.rs",
120106
r#"
121-
#![feature(proc_macro, proc_macro_lib)]
122-
123107
extern crate proc_macro;
124108
use proc_macro::TokenStream;
125109
@@ -137,10 +121,6 @@ fn noop() {
137121

138122
#[test]
139123
fn impl_and_derive() {
140-
if !is_nightly() {
141-
return;
142-
}
143-
144124
let client = project("client")
145125
.file(
146126
"Cargo.toml",
@@ -157,8 +137,6 @@ fn impl_and_derive() {
157137
.file(
158138
"src/main.rs",
159139
r#"
160-
#![feature(proc_macro)]
161-
162140
#[macro_use]
163141
extern crate transmogrify;
164142
@@ -193,8 +171,6 @@ fn impl_and_derive() {
193171
.file(
194172
"src/lib.rs",
195173
r#"
196-
#![feature(proc_macro, proc_macro_lib)]
197-
198174
extern crate proc_macro;
199175
use proc_macro::TokenStream;
200176
@@ -278,9 +254,6 @@ fn plugin_and_proc_macro() {
278254

279255
#[test]
280256
fn proc_macro_doctest() {
281-
if !is_nightly() {
282-
return;
283-
}
284257
let foo = project("foo")
285258
.file(
286259
"Cargo.toml",
@@ -296,7 +269,6 @@ fn proc_macro_doctest() {
296269
.file(
297270
"src/lib.rs",
298271
r#"
299-
#![feature(proc_macro, proc_macro_lib)]
300272
#![crate_type = "proc-macro"]
301273
302274
extern crate proc_macro;

0 commit comments

Comments
 (0)