Skip to content

Commit

Permalink
test: missing opam file now causes build failure
Browse files Browse the repository at this point in the history
Signed-off-by: Etienne Millon <me@emillon.org>
  • Loading branch information
emillon committed Sep 15, 2023
1 parent 4d95fe8 commit f8b7cec
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions test/blackbox-tests/test-cases/missing-opam-generated-file.t
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
This shows a difference since #8518: we set up a project with a generated opam
file. If the resulting file is not present in the repository (or if it has been
renamed to just `opam` as in this example), we now fail.

A related issue happens when `pkg.opam` exists but is not up to date. The
instruction in the opam file would previously consider the original version but
will overwrite `pkg.opam`. Now it does not update the file.

$ cat > dune-project << EOF
> (lang dune 1.10)
> (generate_opam_files)
> (package
> (name pkg))
> EOF

$ touch opam

$ dune build -p pkg @install
Error: No rule found for pkg.opam
-> required by alias install
[1]

0 comments on commit f8b7cec

Please sign in to comment.