Skip to content

Commit 4222164

Browse files
committed
Auto merge of #143888 - matthiaskrgr:rollup-fv9x7kf, r=matthiaskrgr
Rollup of 11 pull requests Successful merges: - rust-lang/rust#143301 (`tests/ui`: A New Order [26/N]) - rust-lang/rust#143519 (Check assoc consts and tys later like assoc fns) - rust-lang/rust#143554 (slice: Mark `rotate_left`, `rotate_right` unstably const) - rust-lang/rust#143634 (interpret/allocation: expose init + write_wildcards on a range) - rust-lang/rust#143685 (Resolve: merge `source_bindings` and `target_bindings` into `bindings`) - rust-lang/rust#143734 (Refactor resolve resolution bindings) - rust-lang/rust#143774 (constify `From` and `Into`) - rust-lang/rust#143785 (Add --compile-time-deps argument for x check) - rust-lang/rust#143786 (Fix fallback for CI_JOB_NAME) - rust-lang/rust#143825 (clippy: fix test filtering when TESTNAME is empty) - rust-lang/rust#143826 (Fix command trace) r? `@ghost` `@rustbot` modify labels: rollup
2 parents 50ffb49 + 7bdb0fd commit 4222164

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

tests/compile-test.rs

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,17 @@ impl TestContext {
144144
let target_dir = PathBuf::from(var_os("CARGO_TARGET_DIR").unwrap_or_else(|| "target".into()));
145145
let mut config = Config {
146146
output_conflict_handling: error_on_output_conflict,
147+
// Pre-fill filters with TESTNAME; will be later extended with `self.args`.
147148
filter_files: env::var("TESTNAME")
148-
.map(|filters| filters.split(',').map(str::to_string).collect())
149+
.map(|filters| {
150+
filters
151+
.split(',')
152+
// Make sure that if TESTNAME is empty we produce the empty list here,
153+
// not a list containing an empty string.
154+
.filter(|s| !s.is_empty())
155+
.map(str::to_string)
156+
.collect()
157+
})
149158
.unwrap_or_default(),
150159
target: None,
151160
bless_command: Some(if IS_RUSTC_TEST_SUITE {

0 commit comments

Comments
 (0)