Add a test exposing a name clash

When several private libraries have the same name, jbuilder crashes.
This commit is contained in:
Jeremie Dimino 2017-12-17 14:55:36 +00:00 committed by Jérémie Dimino
parent 8d0efa347c
commit f534387ef6
8 changed files with 20 additions and 0 deletions

View File

@ -134,3 +134,10 @@
(action
(chdir test-cases/select
(setenv JBUILDER ${bin:jbuilder} (run ${exe:cram.exe} run.t))))))
(alias
((name runtest)
(deps ((files_recursively_in test-cases/multiple-private-libs)))
(action
(chdir test-cases/multiple-private-libs
(setenv JBUILDER ${bin:jbuilder} (run ${exe:cram.exe} run.t))))))

View File

@ -0,0 +1,3 @@
(jbuild_version 1)
(library ((name test)))

View File

@ -0,0 +1 @@
let x = 1

View File

@ -0,0 +1,3 @@
(jbuild_version 1)
(library ((name test)))

View File

@ -0,0 +1 @@
let x = 2

View File

@ -0,0 +1,5 @@
This test checks that there is no clash when two private libraries have the same name
$ $JBUILDER build -j1 --root . @doc
Multiple rules generated for _build/default/_doc/test/index.html
[1]