Skip to content

Commit

Permalink
Merge pull request #3860 from rgrinberg/duniverse-scope-bug
Browse files Browse the repository at this point in the history
Fix cram & vendored dirs bug
  • Loading branch information
rgrinberg authored Oct 13, 2020
2 parents f967df6 + f639ff1 commit 494be34
Show file tree
Hide file tree
Showing 8 changed files with 34 additions and 1 deletion.
3 changes: 3 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ Unreleased
- Do no run ocamldep to for single module executables & libraries. The
dependency graph for such artifacts is trivial (#3847, @rgrinberg)

- Fix cram tests inside vendored directories not being interpreted correctly.
(@rgrinberg, #3860)

2.7.1 (2/09/2020)
-----------------

Expand Down
1 change: 0 additions & 1 deletion src/dune_engine/file_tree.ml
Original file line number Diff line number Diff line change
Expand Up @@ -595,7 +595,6 @@ end = struct
if
Dune_project.cram parent_dir.project
&& Cram_test.is_cram_suffix basename
&& status = Normal
then
Sub_dirs.Status.Data_only
else
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
(lang dune 1.11)
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
; This file is generated by duniverse.
; Be aware that it is likely to be overwritten by your next duniverse pull invocation.

(vendored_dirs *)
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
(lang dune 2.7)
(name dune)
(cram enable)
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
(lang dune 1.11)

(dialect
(name d)
(implementation (extension foo))
(interface (extension bar)))

(dialect
(name d)
(implementation (extension foo2))
(interface (extension bar2)))
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
$ dune build --root bad1
Entering directory 'bad1'
File "dune-project", line 9, characters 1-74:
9 | (name d)
10 | (implementation (extension foo2))
11 | (interface (extension bar2)))
Error: dialect "d" is already defined
[1]
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
This test should demonstrate that cram tests inside the vendor dir have their
directories marked as data only

$ dune build

0 comments on commit 494be34

Please sign in to comment.