summaryrefslogtreecommitdiffstats
path: root/tests/run-make-fulldeps/rustdoc-error-lines/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'tests/run-make-fulldeps/rustdoc-error-lines/Makefile')
-rw-r--r--tests/run-make-fulldeps/rustdoc-error-lines/Makefile13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/run-make-fulldeps/rustdoc-error-lines/Makefile b/tests/run-make-fulldeps/rustdoc-error-lines/Makefile
new file mode 100644
index 000000000..2dc30f56b
--- /dev/null
+++ b/tests/run-make-fulldeps/rustdoc-error-lines/Makefile
@@ -0,0 +1,13 @@
+include ../tools.mk
+
+# Test that hir-tree output doesn't crash and includes
+# the string constant we would expect to see.
+
+all:
+ $(RUSTDOC) --test input.rs > $(TMPDIR)/output || true
+ $(CGREP) 'input.rs - foo (line 5)' < $(TMPDIR)/output
+ $(CGREP) 'input.rs:7:15' < $(TMPDIR)/output
+ $(CGREP) 'input.rs - bar (line 15)' < $(TMPDIR)/output
+ $(CGREP) 'input.rs:17:15' < $(TMPDIR)/output
+ $(CGREP) 'input.rs - bar (line 24)' < $(TMPDIR)/output
+ $(CGREP) 'input.rs:26:15' < $(TMPDIR)/output