Skip to content

Commit

Permalink
fix: print the package name of tests stanza
Browse files Browse the repository at this point in the history
Signed-off-by: Alpha DIALLO <moyodiallo@gmail.com>
  • Loading branch information
moyodiallo committed Jun 8, 2023
1 parent 3593fd1 commit 97b9172
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
4 changes: 3 additions & 1 deletion bin/describe.ml
Original file line number Diff line number Diff line change
Expand Up @@ -693,7 +693,9 @@ module External_lib_deps = struct
resolve_libs db dir tests.exes.buildable.libraries
tests.exes.buildable.preprocess
(List.map tests.exes.names ~f:snd)
tests.exes.package Item.Kind.Tests
(if Option.is_none tests.package then tests.exes.package
else tests.package)
Item.Kind.Tests
(exes_extensions context tests.exes.modes)
>>| List.singleton
| _ -> Memo.return [])
Expand Down
15 changes: 14 additions & 1 deletion test/blackbox-tests/test-cases/external-lib-deps/simple.t/run.t
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ external library dependencies of a simple project
> (library
> (public_name dummypkg)
> (libraries base doesnotexist.foo))
> (test
> (package dummypkg)
> (name test))
> EOF
$ dune describe external-lib-deps
(default
Expand All @@ -14,5 +17,15 @@ external library dependencies of a simple project
(extensions ())
(package (dummypkg))
(source_dir .)
(external_deps ((base required) (doesnotexist.foo required)))
(external_deps
((base required)
(doesnotexist.foo required)))
(internal_deps ())))
(tests
((names (test))
(extensions
(.bc .exe))
(package (dummypkg))
(source_dir .)
(external_deps ())
(internal_deps ())))))

0 comments on commit 97b9172

Please sign in to comment.