Skip to content

Commit

Permalink
test: empty modules + lib + exe
Browse files Browse the repository at this point in the history
Test the situation where we have:

1. an empty library A
2. an executable with a module A
3. conditional module selection in the exe
  • Loading branch information
jonahbeckford authored and rgrinberg committed Feb 28, 2023
1 parent 93e8a95 commit fb6f10f
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
let () = ()
1 change: 1 addition & 0 deletions test/blackbox-tests/test-cases/empty-modules.t/a.unix.ml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
let () = ()
13 changes: 13 additions & 0 deletions test/blackbox-tests/test-cases/empty-modules.t/dune
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
(library
(name a)
(modules))

(executable
(name main)
(modules a main)
(libraries
(select
a.ml
from
(a -> a.pre_413.ml)
(-> a.unix.ml))))
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
(lang dune 2.5)
1 change: 1 addition & 0 deletions test/blackbox-tests/test-cases/empty-modules.t/main.ml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
print_endline "foobar";
5 changes: 5 additions & 0 deletions test/blackbox-tests/test-cases/empty-modules.t/run.t
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
An executable with a module that has the same name as a library in the same
directory.

$ dune exec ./main.exe
foobar

0 comments on commit fb6f10f

Please sign in to comment.