Permalink
Browse files

More tests

Untested as INRIA gforge is down ...
  • Loading branch information...
1 parent 757fe55 commit a779ca38f82257fe40659ca3d6d0bd7530222e0f @samoht samoht committed Mar 15, 2012
View
15 tests/Makefile
@@ -8,7 +8,7 @@ OCPGET_SERVER = ../ocp-get-server --debug --root $(OPAM_SERVER_ROOT)
BACKTRACES = export OCAMLRUNPARAM=b &&
-PACKAGES = P1-1 P2-1 P3-1-weird.version P4-1
+PACKAGES = P1-1 P2-1 P2-1 P3-1-weird.version P4-1
ARCHIVES = $(PACKAGES:%=packages/%.tar.gz)
.PHONY: all upload
@@ -31,9 +31,20 @@ upload: $(ARCHIVES) init
info: upload
$(OCPGET) info
-install:
+install: upload
$(OCPGET) install P1
$(OCPGET) install P2
+ $(OCPGET) install P3
+ $(OCPGET) install P4
+
+upload-new: install
+ cd packages && \
+ cp P1.opam P1.opam.1 && cp P1.opam.2 P1.opam && \
+ $(BACKTRACES) ../$(OCPGET) upload P1 && \
+ cp P1.opam.1 P1.opam
+
+updgrade: upload-new
+ $(OCPGET) upgrade
packages/%.tar.gz: packages/%
cd packages && tar cz $* > $*.tar.gz
View
10 tests/packages/P1-1/p1.ml
@@ -1,13 +1,3 @@
let x () =
try Random.int 10
with _ -> 0
-
-
-
-
-
-
-
-
-
-
View
0 tests/packages/P4-1/P1.install → tests/packages/P1-2/P1.install
File renamed without changes.
View
0 tests/packages/P3-1-weird.version/P1.install → tests/packages/P1-2/build.sh
File renamed without changes.
View
5 tests/packages/P1.opam.2
@@ -0,0 +1,5 @@
+opam-version: 1.0
+
+package: P1
+version: 2
+description: A very useful package
View
0 tests/packages/P2-1/P1.install
No changes.
View
1 tests/packages/P2-1/P2.install
@@ -0,0 +1 @@
+lib: p2.cmo p2.cmx p2.cmi
View
1 tests/packages/P3-1-weird.version/P3.install
@@ -0,0 +1 @@
+lib: p3.cma p3.cmxa p3.cmi
View
1 tests/packages/P3-1-weird.version/build.sh
@@ -0,0 +1 @@
+ocamlbuild -I `$(OCPGET) info -dir P1` p3.cma p3.cmxa
View
3 tests/packages/P3-1-weird.version/p3.ml
@@ -0,0 +1,3 @@
+let z () =
+ try P1.x ()
+ with _ -> 0
View
1 tests/packages/P4-1/P4.install
@@ -0,0 +1 @@
+lib: p4.cma p4.cmxa p4.cmi
View
1 tests/packages/P4-1/build.sh
@@ -0,0 +1 @@
+ocamlbuild `$(OCPGET config -r -dir P2)` `$(OCPGET config -r -dir P3)` p4.cma p4.cmxa
View
23 tests/packages/P4-1/p4.ml
@@ -0,0 +1,23 @@
+let f =
+ try P2.x ()
+ with P3.x ()
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+

0 comments on commit a779ca3

Please sign in to comment.