aboutsummaryrefslogtreecommitdiff
path: root/test-suite/coq-makefile/coqdoc1
diff options
context:
space:
mode:
authorEnrico Tassi2017-01-23 17:18:39 +0100
committerEnrico Tassi2017-05-23 10:48:27 +0200
commite9156da20ec5332b1b53a6c44127e0f822891d16 (patch)
tree87574e62f236faa8c0c00393d78b1e5233cfe490 /test-suite/coq-makefile/coqdoc1
parentcd8f10fe54c956f1e797da3d165c3b29ffee615b (diff)
test suite for coq_makefile
Diffstat (limited to 'test-suite/coq-makefile/coqdoc1')
-rw-r--r--test-suite/coq-makefile/coqdoc1/_CoqProject11
-rwxr-xr-xtest-suite/coq-makefile/coqdoc1/run.sh53
-rw-r--r--test-suite/coq-makefile/coqdoc1/src/test.ml413
-rw-r--r--test-suite/coq-makefile/coqdoc1/src/test.mli0
-rw-r--r--test-suite/coq-makefile/coqdoc1/src/test_aux.ml1
-rw-r--r--test-suite/coq-makefile/coqdoc1/src/test_aux.mli1
-rw-r--r--test-suite/coq-makefile/coqdoc1/src/test_plugin.mlpack2
-rw-r--r--test-suite/coq-makefile/coqdoc1/theories/sub/testsub.v1
-rw-r--r--test-suite/coq-makefile/coqdoc1/theories/test.v7
9 files changed, 89 insertions, 0 deletions
diff --git a/test-suite/coq-makefile/coqdoc1/_CoqProject b/test-suite/coq-makefile/coqdoc1/_CoqProject
new file mode 100644
index 0000000000..35792066bb
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/_CoqProject
@@ -0,0 +1,11 @@
+-R src test
+-R theories test
+-I src
+
+src/test_plugin.mlpack
+src/test.ml4
+src/test.mli
+src/test_aux.ml
+src/test_aux.mli
+theories/test.v
+theories/sub/testsub.v
diff --git a/test-suite/coq-makefile/coqdoc1/run.sh b/test-suite/coq-makefile/coqdoc1/run.sh
new file mode 100755
index 0000000000..bbe9717ab9
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/run.sh
@@ -0,0 +1,53 @@
+#!/bin/bash
+
+#set -x
+set -e
+
+export PATH=../../../bin/:$PATH
+git clean -dfx .
+coq_makefile -f _CoqProject -o Makefile
+make
+make html mlihtml
+make install DSTROOT="$PWD/tmp"
+make install-doc DSTROOT="$PWD/tmp"
+#make debug
+(for d in `find tmp -name user-contrib`; do pushd $d >/dev/null; find; popd >/dev/null; done) | sort -u > actual
+sort -u > desired <<EOT
+.
+./test
+./test/test_plugin.cmi
+./test/test_plugin.cmo
+./test/test_plugin.cmx
+./test/test_plugin.cmxs
+./test/test.glob
+./test/test.v
+./test/test.vo
+./test/sub
+./test/sub/testsub.glob
+./test/sub/testsub.v
+./test/sub/testsub.vo
+./test/mlihtml
+./test/mlihtml/index_exceptions.html
+./test/mlihtml/index.html
+./test/mlihtml/index_class_types.html
+./test/mlihtml/type_Test_aux.html
+./test/mlihtml/index_module_types.html
+./test/mlihtml/index_classes.html
+./test/mlihtml/type_Test.html
+./test/mlihtml/style.css
+./test/mlihtml/index_attributes.html
+./test/mlihtml/index_types.html
+./test/mlihtml/Test_aux.html
+./test/mlihtml/index_values.html
+./test/mlihtml/Test.html
+./test/mlihtml/index_extensions.html
+./test/mlihtml/index_methods.html
+./test/mlihtml/index_modules.html
+./test/html
+./test/html/index.html
+./test/html/test.sub.testsub.html
+./test/html/toc.html
+./test/html/coqdoc.css
+./test/html/test.test.html
+EOT
+exec diff -u desired actual
diff --git a/test-suite/coq-makefile/coqdoc1/src/test.ml4 b/test-suite/coq-makefile/coqdoc1/src/test.ml4
new file mode 100644
index 0000000000..8ddc9b0956
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/src/test.ml4
@@ -0,0 +1,13 @@
+DECLARE PLUGIN "test_plugin"
+let () = Mltop.add_known_plugin (fun () -> ()) "test_plugin";;
+
+VERNAC COMMAND EXTEND Test CLASSIFIED AS SIDEFF
+ | [ "Test" ] -> [ () ]
+END
+
+TACTIC EXTEND test
+| [ "test" ] -> [ Test_aux.tac ]
+END
+
+
+
diff --git a/test-suite/coq-makefile/coqdoc1/src/test.mli b/test-suite/coq-makefile/coqdoc1/src/test.mli
new file mode 100644
index 0000000000..e69de29bb2
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/src/test.mli
diff --git a/test-suite/coq-makefile/coqdoc1/src/test_aux.ml b/test-suite/coq-makefile/coqdoc1/src/test_aux.ml
new file mode 100644
index 0000000000..a01d0865a8
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/src/test_aux.ml
@@ -0,0 +1 @@
+let tac = Proofview.tclUNIT ()
diff --git a/test-suite/coq-makefile/coqdoc1/src/test_aux.mli b/test-suite/coq-makefile/coqdoc1/src/test_aux.mli
new file mode 100644
index 0000000000..10020f27de
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/src/test_aux.mli
@@ -0,0 +1 @@
+val tac : unit Proofview.tactic
diff --git a/test-suite/coq-makefile/coqdoc1/src/test_plugin.mlpack b/test-suite/coq-makefile/coqdoc1/src/test_plugin.mlpack
new file mode 100644
index 0000000000..cf94d851bb
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/src/test_plugin.mlpack
@@ -0,0 +1,2 @@
+Test_aux
+Test
diff --git a/test-suite/coq-makefile/coqdoc1/theories/sub/testsub.v b/test-suite/coq-makefile/coqdoc1/theories/sub/testsub.v
new file mode 100644
index 0000000000..755fc343f2
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/theories/sub/testsub.v
@@ -0,0 +1 @@
+Require Import test.
diff --git a/test-suite/coq-makefile/coqdoc1/theories/test.v b/test-suite/coq-makefile/coqdoc1/theories/test.v
new file mode 100644
index 0000000000..7753b56aae
--- /dev/null
+++ b/test-suite/coq-makefile/coqdoc1/theories/test.v
@@ -0,0 +1,7 @@
+Declare ML Module "test_plugin".
+Test.
+Goal True.
+Proof.
+test.
+exact I.
+Qed.