aboutsummaryrefslogtreecommitdiff
path: root/test-suite
diff options
context:
space:
mode:
Diffstat (limited to 'test-suite')
-rw-r--r--test-suite/Makefile18
-rw-r--r--test-suite/bugs/closed/bug_11342.v19
-rw-r--r--test-suite/output/bug_11342.out1
-rw-r--r--test-suite/output/bug_11342.v12
-rw-r--r--test-suite/output/bug_11608.out1
-rw-r--r--test-suite/output/bug_11608.v13
6 files changed, 57 insertions, 7 deletions
diff --git a/test-suite/Makefile b/test-suite/Makefile
index 265c2eafa7..1681150f7b 100644
--- a/test-suite/Makefile
+++ b/test-suite/Makefile
@@ -32,11 +32,15 @@ include ../Makefile.common
# Variables
#######################################################################
+# Using quotes to anticipate the possibility of spaces in the directory name
+# Note that this will later need an eval in shell to interpret the quotes
+ROOT='$(shell cd ..; pwd)'
+
ifneq ($(wildcard ../_build),)
-BIN:=$(shell cd ..; pwd)/_build/install/default/bin/
-COQLIB:=$(shell cd ..; pwd)/_build/install/default/lib/coq
+BIN:=$(ROOT)/_build/install/default/bin/
+COQLIB:=$(ROOT)/_build/install/default/lib/coq
else
-BIN := $(shell cd ..; pwd)/bin/
+BIN := $(ROOT)/bin/
COQLIB?=
ifeq ($(COQLIB),)
@@ -602,10 +606,10 @@ $(patsubst %.sh,%.log,$(wildcard misc/*.sh)): %.log: %.sh $(PREREQUISITELOG)
@echo "TEST $<"
$(HIDE){ \
echo $(call log_intro,$<); \
- export BIN="$(BIN)"; \
- export coqc="$(coqc)"; \
- export coqtop="$(coqc)"; \
- export coqdep="$(coqdep)"; \
+ export BIN=$(BIN); \
+ export coqc="eval $(coqc)"; \
+ export coqtop="eval $(coqc)"; \
+ export coqdep="eval $(coqdep)"; \
"$<" 2>&1; R=$$?; times; \
if [ $$R = 0 ]; then \
echo $(log_success); \
diff --git a/test-suite/bugs/closed/bug_11342.v b/test-suite/bugs/closed/bug_11342.v
new file mode 100644
index 0000000000..3c163fb772
--- /dev/null
+++ b/test-suite/bugs/closed/bug_11342.v
@@ -0,0 +1,19 @@
+(* -*- mode: coq; coq-prog-args: ("-vos") -*- *)
+
+Section foo.
+ Context {H:True}.
+ Set Default Proof Using "Type".
+ Theorem test2 : True.
+ Proof.
+ (* BUG: this gets run when compiling with -vos *)
+ fail "proof with default using".
+ exact I.
+ Qed.
+
+ Theorem test3 : True.
+ Proof using Type.
+ (* this isn't run with -vos *)
+ fail "using".
+ exact I.
+ Qed.
+End foo.
diff --git a/test-suite/output/bug_11342.out b/test-suite/output/bug_11342.out
new file mode 100644
index 0000000000..9aac16de0d
--- /dev/null
+++ b/test-suite/output/bug_11342.out
@@ -0,0 +1 @@
+without using
diff --git a/test-suite/output/bug_11342.v b/test-suite/output/bug_11342.v
new file mode 100644
index 0000000000..73131a3190
--- /dev/null
+++ b/test-suite/output/bug_11342.v
@@ -0,0 +1,12 @@
+(* -*- mode: coq; coq-prog-args: ("-vos") -*- *)
+
+Section foo.
+ Context {H:True}.
+ Theorem test1 : True.
+ Proof.
+ (* this gets printed with -vos because there's no annotation (either [Set
+ Default Proof Using ...] or an explicit [Proof using ...]) *)
+ idtac "without using".
+ exact I.
+ Qed.
+End foo.
diff --git a/test-suite/output/bug_11608.out b/test-suite/output/bug_11608.out
new file mode 100644
index 0000000000..793ff768d4
--- /dev/null
+++ b/test-suite/output/bug_11608.out
@@ -0,0 +1 @@
+creating x without [Proof.]
diff --git a/test-suite/output/bug_11608.v b/test-suite/output/bug_11608.v
new file mode 100644
index 0000000000..3929082913
--- /dev/null
+++ b/test-suite/output/bug_11608.v
@@ -0,0 +1,13 @@
+(* -*- mode: coq; coq-prog-args: ("-vos") -*- *)
+
+Set Default Proof Using "Type".
+
+Section foo.
+ Context (A:Type).
+ Definition x : option A.
+ (* this can get printed with -vos since without "Proof." there's no Proof
+ using, even with a default annotation. *)
+ idtac "creating x without [Proof.]".
+ exact None.
+ Qed.
+End foo.