This commit is contained in:
parent
aa2ff7b2f0
commit
2f3113f55d
11742 changed files with 1223940 additions and 0 deletions
41
unikernel/duniverse/camlp-streams/test/dune
Normal file
41
unikernel/duniverse/camlp-streams/test/dune
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
(library
|
||||
(name stream_stdlib)
|
||||
(flags :standard -w -3)
|
||||
(modules stream_stdlib)
|
||||
(enabled_if (< %{ocaml_version} 5.0)))
|
||||
|
||||
(library
|
||||
(name stream_camlp_streams)
|
||||
(libraries camlp-streams)
|
||||
(modules stream_camlp_streams))
|
||||
|
||||
(executable
|
||||
(name equality)
|
||||
(libraries stream_stdlib stream_camlp_streams)
|
||||
(modules equality)
|
||||
(enabled_if (< %{ocaml_version} 5.0)))
|
||||
|
||||
(rule
|
||||
(action (with-stdout-to equality.output (run ./equality.exe)))
|
||||
(enabled_if (< %{ocaml_version} 5.0)))
|
||||
|
||||
(rule
|
||||
(alias runtest)
|
||||
(action (diff equality.expected equality.output))
|
||||
(enabled_if (< %{ocaml_version} 5.0)))
|
||||
|
||||
(executable
|
||||
(name linking)
|
||||
(libraries camlp-streams stream_stdlib)
|
||||
(modules linking)
|
||||
(flags :standard -w -3)
|
||||
(enabled_if (< %{ocaml_version} 5.0)))
|
||||
|
||||
(rule
|
||||
(action (with-stdout-to issue4.output (run ./linking.exe)))
|
||||
(enabled_if (< %{ocaml_version} 5.0)))
|
||||
|
||||
(rule
|
||||
(alias runtest)
|
||||
(action (diff issue4.expected issue4.output))
|
||||
(enabled_if (< %{ocaml_version} 5.0)))
|
||||
6
unikernel/duniverse/camlp-streams/test/equality.ml
Normal file
6
unikernel/duniverse/camlp-streams/test/equality.ml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
(* Test type equality between a library using camlp-streams and one using
|
||||
Stdlib.Stream *)
|
||||
|
||||
let () =
|
||||
Stream.empty Stream_stdlib.stream;
|
||||
Stream.empty Stream_camlp_streams.stream
|
||||
6
unikernel/duniverse/camlp-streams/test/linking.ml
Normal file
6
unikernel/duniverse/camlp-streams/test/linking.ml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
(* Test that we can link programs using libraries which use Stream.t but don't
|
||||
necessarily use camlp-streams. Test is most relevant on 4.02-4.06 before the
|
||||
Stdlib module was introduced. *)
|
||||
|
||||
let () =
|
||||
Stream.(empty (Stream.of_list Stream_stdlib.list))
|
||||
|
|
@ -0,0 +1 @@
|
|||
let stream = Stream.of_list ([] : unit list)
|
||||
2
unikernel/duniverse/camlp-streams/test/stream_stdlib.ml
Normal file
2
unikernel/duniverse/camlp-streams/test/stream_stdlib.ml
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
let list = ([] : unit list)
|
||||
let stream = Stream.of_list list
|
||||
Loading…
Add table
Add a link
Reference in a new issue