Skip to content

Commit e2bd0c5

Browse files
authored
Fix tests not passing in Opam (#2635)
Bug introduced in #2618. The tests don't pass when run with `dune build -p` option, as it's done in Opam.
1 parent 70830b5 commit e2bd0c5

File tree

8 files changed

+1258
-316
lines changed

8 files changed

+1258
-316
lines changed

Diff for: test/passing/gen/dune.inc

+1,248-312
Large diffs are not rendered by default.

Diff for: test/passing/gen/gen.ml

+4-1
Original file line numberDiff line numberDiff line change
@@ -106,18 +106,21 @@ let emit_test test_name setup =
106106
Printf.printf
107107
{|
108108
(rule
109-
(deps .ocamlformat dune-project)%s
109+
(deps .ocamlformat .hg)%s
110+
(package ocamlformat)
110111
(action
111112
(with-stdout-to %s
112113
(with-stderr-to %s.stderr
113114
%s))))
114115

115116
(rule
116117
(alias runtest)%s
118+
(package ocamlformat)
117119
(action (diff %s %s.stdout)))
118120

119121
(rule
120122
(alias runtest)%s
123+
(package ocamlformat)
121124
(action (diff %s %s.stderr)))
122125
|}
123126
enabled_if_line output_fname test_name

Diff for: test/passing/refs.default/.hg

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
This file ensures that OCamlformat don't consider parent directories when
2+
searching for configuration.

Diff for: test/passing/refs.default/dune-project

-1
This file was deleted.

Diff for: test/passing/refs.janestreet/.hg

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
This file ensures that OCamlformat don't consider parent directories when
2+
searching for configuration.

Diff for: test/passing/refs.janestreet/dune-project

-1
This file was deleted.

Diff for: test/passing/refs.ocamlformat/.hg

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
This file ensures that OCamlformat don't consider parent directories when
2+
searching for configuration.

Diff for: test/passing/refs.ocamlformat/dune-project

-1
This file was deleted.

0 commit comments

Comments
 (0)