summaryrefslogtreecommitdiffstats
path: root/tests/run-make/weird-output-filenames/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'tests/run-make/weird-output-filenames/Makefile')
-rw-r--r--tests/run-make/weird-output-filenames/Makefile15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/run-make/weird-output-filenames/Makefile b/tests/run-make/weird-output-filenames/Makefile
new file mode 100644
index 000000000..d3a34e3b4
--- /dev/null
+++ b/tests/run-make/weird-output-filenames/Makefile
@@ -0,0 +1,15 @@
+include ../tools.mk
+
+all:
+ cp foo.rs $(TMPDIR)/.foo.rs
+ $(RUSTC) $(TMPDIR)/.foo.rs 2>&1 \
+ | $(CGREP) -e "invalid character.*in crate name:"
+ cp foo.rs $(TMPDIR)/.foo.bar
+ $(RUSTC) $(TMPDIR)/.foo.bar 2>&1 \
+ | $(CGREP) -e "invalid character.*in crate name:"
+ cp foo.rs $(TMPDIR)/+foo+bar.rs
+ $(RUSTC) $(TMPDIR)/+foo+bar.rs 2>&1 \
+ | $(CGREP) -e "invalid character.*in crate name:"
+ cp foo.rs $(TMPDIR)/-foo.rs
+ $(RUSTC) $(TMPDIR)/-foo.rs 2>&1 \
+ | $(CGREP) 'crate names cannot start with a `-`'