Skip to content

Commit 56fe015

Browse files
committed
Migrate weird-output-filenames to rmake
1 parent 614e042 commit 56fe015

File tree

3 files changed

+19
-16
lines changed

3 files changed

+19
-16
lines changed

src/tools/tidy/src/allowed_run_make_makefiles.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,5 +188,4 @@ run-make/type-mismatch-same-crate-name/Makefile
188188
run-make/unstable-flag-required/Makefile
189189
run-make/wasm-exceptions-nostd/Makefile
190190
run-make/wasm-override-linker/Makefile
191-
run-make/weird-output-filenames/Makefile
192191
run-make/x86_64-fortanix-unknown-sgx-lvi/Makefile

tests/run-make/weird-output-filenames/Makefile

Lines changed: 0 additions & 15 deletions
This file was deleted.
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
use run_make_support::fs_wrapper::copy;
2+
use run_make_support::regex::Regex;
3+
use run_make_support::{cwd, rustc};
4+
5+
fn main() {
6+
let invalid_characters = [".foo.rs", ".foo.bar", "+foo+bar.rs"];
7+
let re = Regex::new(r"invalid character.*in crate name:").unwrap();
8+
for f in invalid_characters {
9+
copy("foo.rs", f);
10+
let stderr = rustc().input(f).run_fail().stderr_utf8();
11+
assert!(re.is_match(&stderr));
12+
}
13+
14+
copy("foo.rs", "-foo.rs");
15+
rustc()
16+
.input(cwd().join("-foo.rs"))
17+
.run_fail()
18+
.assert_stderr_contains("crate names cannot start with a `-`");
19+
}

0 commit comments

Comments
 (0)