From 8d1fcc98870bdca5e82d334082fc94763ef4036f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Pit-Claudel?= Date: Wed, 9 Nov 2022 20:11:21 -0600 Subject: [PATCH] fix: print "Leaving Directory" Print "Leaving Directory '%s'" in addition to "Entering Directory" Fixes #138 Signed-off-by: Rudi Grinberg ps-id: 462a51cc-0bc8-44da-85d2-027bc1e372d7 --- bin/common.ml | 7 ++++-- otherlibs/site/test/run.t | 5 +++++ otherlibs/site/test/run_2_9.t | 4 ++++ .../test-cases/bad-alias-error.t/run.t | 2 ++ .../test-cases/copy_files.t/run.t | 9 +++++++- .../test-cases/depend-on/installed-packages.t | 9 ++++++++ .../test-cases/dune-init.t/run.t | 5 +++++ .../test-cases/dune-jbuild-var-case.t/run.t | 2 ++ .../test-cases/dune-package.t/run.t | 4 ++++ .../test-cases/dune-ppx-driver-system.t/run.t | 14 ++++++++++++ .../test-cases/dune-project-meta/main.t/run.t | 11 ++++++++++ .../test-cases/dup-fields.t/run.t | 1 + .../test-cases/duplicate-c-cxx-obj.t/run.t | 3 +++ .../test-cases/duplicate-c-cxx.t/run.t | 2 ++ .../test-cases/enabled_if-exec.t/run.t | 7 ++++++ .../test-cases/exec-cmd.t/run.t | 1 + .../test-cases/exes-with-c.t/run.t | 1 + .../test-cases/fallback-dune.t/run.t | 2 ++ .../test-cases/findlib-error.t/run.t | 1 + .../test-cases/foreign-library.t | 3 +++ .../test-cases/github1099.t/run.t | 2 ++ .../test-cases/github1549.t/run.t | 2 ++ .../test-cases/github1616.t/run.t | 1 + .../test-cases/ignored_subdirs.t/run.t | 5 +++++ .../test-cases/inline_tests/dune-file.t/run.t | 1 + .../inline_tests/executable-flags.t/run.t | 1 + .../test-cases/instrumentation.t/run.t | 1 + .../test-cases/intf-only.t/run.t | 5 +++++ test/blackbox-tests/test-cases/lib.t | 1 + test/blackbox-tests/test-cases/libexec.t | 2 ++ .../blackbox-tests/test-cases/link-includes.t | 2 ++ .../test-cases/meta-template-version-bug.t | 1 + .../test-cases/missing-loc-run.t/run.t | 3 +++ .../test-cases/no-installable-mode.t/run.t | 2 ++ .../test-cases/ocamldep-multi-stanzas.t/run.t | 2 ++ .../test-cases/old-dune-subsystem.t/run.t | 1 + .../test-cases/path-variables.t/run.t | 3 ++- .../test-cases/private-package-lib/main.t | 2 ++ .../blackbox-tests/test-cases/quoting.t/run.t | 7 +++++- .../test-cases/re-exported-deps.t/run.t | 3 +++ test/blackbox-tests/test-cases/reason.t/run.t | 1 + .../test-cases/rule-target-inferrence.t/run.t | 6 +++-- .../test-cases/rule/dependency-external.t | 22 +++++++++++++++++++ .../test-cases/several-packages.t/run.t | 3 +++ .../test-cases/target-dir-alias.t/run.t | 2 +- .../variables-for-artifacts.t/run.t | 4 ++++ .../test-cases/vendor/main.t/run.t | 13 +++++++++-- .../impl-not-virtual-external.t | 2 ++ .../implements-external.t/run.t | 5 +++++ .../virtual-libraries/unwrapped.t/run.t | 2 ++ .../vlib-default-impl/external.t/run.t | 2 ++ .../workspaces/workspace-paths.t/run.t | 1 + .../test-cases/write-permissions.t | 3 +++ 53 files changed, 196 insertions(+), 10 deletions(-) diff --git a/bin/common.ml b/bin/common.ml index 9ebd47b48569..f39be6eb0626 100644 --- a/bin/common.ml +++ b/bin/common.ml @@ -111,7 +111,7 @@ let normalize_path path = let print_entering_message c = let cwd = Path.to_absolute_filename Path.root in - if cwd <> Fpath.initial_cwd && not c.no_print_directory then + if cwd <> Fpath.initial_cwd && not c.no_print_directory then ( (* Editors such as Emacs parse the output of the build system and interpret filenames in error messages relative to where the build system was started. @@ -144,7 +144,10 @@ let print_entering_message c = in loop ".." (Filename.dirname s))) in - Console.print [ Pp.verbatim (sprintf "Entering directory '%s'" dir) ] + Console.print [ Pp.verbatim (sprintf "Entering directory '%s'" dir) ]; + at_exit (fun () -> + flush stdout; + Console.print [ Pp.verbatim (sprintf "Leaving directory '%s'" dir) ])) let init ?log_file c = if c.root.dir <> Filename.current_dir_name then Sys.chdir c.root.dir; diff --git a/otherlibs/site/test/run.t b/otherlibs/site/test/run.t index 4eb0de026f74..12072fa8b717 100644 --- a/otherlibs/site/test/run.t +++ b/otherlibs/site/test/run.t @@ -335,9 +335,11 @@ Test compiling an external plugin $ OCAMLPATH=$(pwd)/_install/lib:$OCAMLPATH dune build --root=e Entering directory 'e' + Leaving directory 'e' $ OCAMLPATH=$(pwd)/_install/lib:$OCAMLPATH PATH=$(pwd)/_install/bin:$PATH dune exec --root=e -- c Entering directory 'e' + Leaving directory 'e' run a a: $TESTCASE_ROOT/_install/share/a/data run c: a linked registered:. @@ -354,6 +356,7 @@ Test compiling an external plugin $ OCAMLPATH=$(pwd)/_install/lib:$OCAMLPATH dune install --root=e --prefix $(pwd)/_install 2>&1 | sed -e "/^Installing/d" Entering directory 'e' + Leaving directory 'e' $ OCAMLPATH=_install/lib:$OCAMLPATH _install/bin/c run a @@ -411,6 +414,7 @@ Test %{version:installed-pkg} $ OCAMLPATH=_install/lib:$OCAMLPATH dune build --root=f Entering directory 'f' + Leaving directory 'f' $ cat $(pwd)/f/_build/default/test.target a = 0.a e = @@ -423,6 +427,7 @@ Test %{version:installed-pkg} ^^^^^^^^^^^^^^^^^ Error: Library names are not allowed in this position. Only package names are allowed + Leaving directory 'f' [1] $ rm f/dune diff --git a/otherlibs/site/test/run_2_9.t b/otherlibs/site/test/run_2_9.t index 2410ec00b80e..f41549ecffad 100644 --- a/otherlibs/site/test/run_2_9.t +++ b/otherlibs/site/test/run_2_9.t @@ -320,9 +320,11 @@ Test compiling an external plugin $ OCAMLPATH=$(pwd)/_install/lib:$OCAMLPATH dune build --root=e Entering directory 'e' + Leaving directory 'e' $ OCAMLPATH=$(pwd)/_install/lib:$OCAMLPATH PATH=$(pwd)/_install/bin:$PATH dune exec --root=e -- c Entering directory 'e' + Leaving directory 'e' run a a: $TESTCASE_ROOT/_install/share/a/data run c: a linked registered:. @@ -395,6 +397,7 @@ Test %{version:installed-pkg} $ OCAMLPATH=_install/lib:$OCAMLPATH dune build --root=f Entering directory 'f' + Leaving directory 'f' $ cat $(pwd)/f/_build/default/test.target a = 0.a e = @@ -407,6 +410,7 @@ Test %{version:installed-pkg} ^^^^^^^^^^^^^^^^^ Error: Library names are not allowed in this position. Only package names are allowed + Leaving directory 'f' [1] $ rm f/dune diff --git a/test/blackbox-tests/test-cases/bad-alias-error.t/run.t b/test/blackbox-tests/test-cases/bad-alias-error.t/run.t index 91266a67d79f..fedc265a46c0 100644 --- a/test/blackbox-tests/test-cases/bad-alias-error.t/run.t +++ b/test/blackbox-tests/test-cases/bad-alias-error.t/run.t @@ -5,6 +5,7 @@ ^^^^^^^^ Error: Invalid alias! Tried to reference path outside build dir: "/foo/bar" + Leaving directory 'absolute-path' [1] $ dune runtest --root outside-workspace Entering directory 'outside-workspace' @@ -12,4 +13,5 @@ 4 | (alias %{workspace_root}/../../../foobar))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Error: path outside the workspace: ./../../../foobar from default + Leaving directory 'outside-workspace' [1] diff --git a/test/blackbox-tests/test-cases/copy_files.t/run.t b/test/blackbox-tests/test-cases/copy_files.t/run.t index 4a62a73eff96..6a6c93d3cf2e 100644 --- a/test/blackbox-tests/test-cases/copy_files.t/run.t +++ b/test/blackbox-tests/test-cases/copy_files.t/run.t @@ -2,14 +2,16 @@ Test that (copy_files ...) works $ dune build --root test1 test.exe .merlin-conf/lib-foo .merlin-conf/exe-test Entering directory 'test1' + Leaving directory 'test1' $ dune build --root test1 @bar-source Entering directory 'test1' #line 1 "include/bar.h" int foo () {return 42;} + Leaving directory 'test1' $ dune build --root test2 @foo/cat Entering directory 'test2' # 1 "dummy.txt" - hello + helloLeaving directory 'test2' Test (alias ...) and (mode ...) fields: @@ -33,6 +35,7 @@ Test (alias ...) and (mode ...) fields: ^^^^^^^^^^^ Error: 'alias' is only available since version 2.7 of the dune language. Please update your dune-project file to have (lang dune 2.7). + Leaving directory 'test3' [1] $ cat >test3/dune-project < EOF $ dune build --root test4 $(basename $P) Entering directory 'test4' + Leaving directory 'test4' $ cat test4/_build/default/$(basename $P) Hola @@ -75,6 +80,7 @@ Test (enabled_if ...) > EOF $ dune build --root test5 Entering directory 'test5' + Leaving directory 'test5' $ ls test5/_build/default | grep foo.txt [1] $ cat >test5/dune < EOF $ dune build --root test5 Entering directory 'test5' + Leaving directory 'test5' $ ls test5/_build/default | grep foo.txt foo.txt diff --git a/test/blackbox-tests/test-cases/depend-on/installed-packages.t b/test/blackbox-tests/test-cases/depend-on/installed-packages.t index abf3ce6cac21..f765864215a8 100644 --- a/test/blackbox-tests/test-cases/depend-on/installed-packages.t +++ b/test/blackbox-tests/test-cases/depend-on/installed-packages.t @@ -17,12 +17,14 @@ $ dune build --root a Entering directory 'a' + Leaving directory 'a' $ dune install --root a --prefix $(pwd)/prefix Entering directory 'a' Installing $TESTCASE_ROOT/prefix/lib/a/META Installing $TESTCASE_ROOT/prefix/lib/a/dune-package Installing $TESTCASE_ROOT/prefix/share/a/CATME + Leaving directory 'a' $ cat >b/dune-project < (lang dune 2.9) @@ -36,9 +38,11 @@ $ OCAMLPATH=$(pwd)/prefix/lib/:$OCAMLPATH dune build --root b @runtest Entering directory 'b' Miaou + Leaving directory 'b' $ OCAMLPATH=$(pwd)/prefix/lib/:$OCAMLPATH dune build --root b @runtest Entering directory 'b' + Leaving directory 'b' $ rm a/CATME $ cat >a/CATME <b/dune-project < (lang dune 2.8) @@ -75,4 +83,5 @@ 1 | (rule (alias runtest) (deps (package a)) (action (run cat $TESTCASE_ROOT/prefix/share/a/CATME))) ^ Error: Dependency on an installed package requires at least (lang dune 2.9) + Leaving directory 'b' [1] diff --git a/test/blackbox-tests/test-cases/dune-init.t/run.t b/test/blackbox-tests/test-cases/dune-init.t/run.t index 1a1d084d0a3c..ddb2839ae274 100644 --- a/test/blackbox-tests/test-cases/dune-init.t/run.t +++ b/test/blackbox-tests/test-cases/dune-init.t/run.t @@ -346,6 +346,7 @@ We can build the project: $ dune build --root test_exec_proj Entering directory 'test_exec_proj' + Leaving directory 'test_exec_proj' And the opam file will be generated as expected @@ -386,12 +387,14 @@ We can build and run the resulting executable: $ dune exec --root test_exec_proj ./bin/main.exe Entering directory 'test_exec_proj' + Leaving directory 'test_exec_proj' Hello, World! We can build and run the project's tests: $ dune exec --root test_exec_proj ./test/test_exec_proj.exe Entering directory 'test_exec_proj' + Leaving directory 'test_exec_proj' Initializing library projects ================================ @@ -448,6 +451,7 @@ We can build and install the project: $ dune build --root test_lib_proj @install Entering directory 'test_lib_proj' + Leaving directory 'test_lib_proj' And the opam file will be generated as expected @@ -492,6 +496,7 @@ And we we can run the tests: ocamlopt test/.test_lib_proj.eobjs/native/dune__exe__Test_lib_proj.{cmx,o} ocamlopt test/test_lib_proj.exe test_lib_proj alias test/runtest + Leaving directory 'test_lib_proj' Initializing projects using Esy =============================== diff --git a/test/blackbox-tests/test-cases/dune-jbuild-var-case.t/run.t b/test/blackbox-tests/test-cases/dune-jbuild-var-case.t/run.t index 4ca33eac9207..21f4c7652f74 100644 --- a/test/blackbox-tests/test-cases/dune-jbuild-var-case.t/run.t +++ b/test/blackbox-tests/test-cases/dune-jbuild-var-case.t/run.t @@ -2,6 +2,7 @@ All builtin variables are lower cased in Dune: $ dune runtest --root dune-lower Entering directory 'dune-lower' + Leaving directory 'dune-lower' $ dune runtest --root dune-upper Entering directory 'dune-upper' @@ -10,4 +11,5 @@ All builtin variables are lower cased in Dune: ^^^^^^^ Error: %{MAKE} was renamed to '%{make}' in the 1.0 version of the dune language + Leaving directory 'dune-upper' [1] diff --git a/test/blackbox-tests/test-cases/dune-package.t/run.t b/test/blackbox-tests/test-cases/dune-package.t/run.t index 89c9b179c0e6..600bfc072e9a 100644 --- a/test/blackbox-tests/test-cases/dune-package.t/run.t +++ b/test/blackbox-tests/test-cases/dune-package.t/run.t @@ -3,6 +3,7 @@ $ dune build --root=a Entering directory 'a' + Leaving directory 'a' $ dune_cmd cat a/_build/install/default/lib/a/dune-package | sed "s/(lang dune .*)/(lang dune )/" | dune_cmd sanitize (lang dune ) (name a) @@ -106,6 +107,7 @@ Build with "--store-orig-source-dir" profile $ dune build --root=a --store-orig-source-dir Entering directory 'a' + Leaving directory 'a' $ dune_cmd cat a/_build/install/default/lib/a/dune-package | grep -A 1 '(orig_src_dir' (orig_src_dir $TESTCASE_ROOT/a) @@ -119,6 +121,7 @@ Build with "--store-orig-source-dir" profile Build with "DUNE_STORE_ORIG_SOURCE_DIR=true" profile $ DUNE_STORE_ORIG_SOURCE_DIR=true dune build --root=a Entering directory 'a' + Leaving directory 'a' $ dune_cmd cat a/_build/install/default/lib/a/dune-package | grep -A 1 '(orig_src_dir' (orig_src_dir $TESTCASE_ROOT/a) @@ -133,6 +136,7 @@ Install the package directly $ dune install "--prefix=$PWD/prefix" --root=a 2>&1 | grep -v "Installing" Entering directory 'a' + Leaving directory 'a' $ dune_cmd cat prefix/lib/a/dune-package | grep -e 'lib/a' -e 'share/a' $TESTCASE_ROOT/prefix/lib/a) diff --git a/test/blackbox-tests/test-cases/dune-ppx-driver-system.t/run.t b/test/blackbox-tests/test-cases/dune-ppx-driver-system.t/run.t index 5c4c17a35f51..a9e0a90beefb 100644 --- a/test/blackbox-tests/test-cases/dune-ppx-driver-system.t/run.t +++ b/test/blackbox-tests/test-cases/dune-ppx-driver-system.t/run.t @@ -15,6 +15,7 @@ No ppx driver found 5 | (preprocess (pps))) ^^^^^ Error: You must specify at least one ppx rewriter. + Leaving directory 'no-driver' [1] Too many drivers @@ -26,6 +27,7 @@ Too many drivers ^^^^^^^^^^^^^^^ Error: Too many incompatible ppx drivers were found: foo.driver1 and foo.driver2. + Leaving directory 'driver-tests' [1] Not compatible with Dune @@ -38,6 +40,7 @@ Not compatible with Dune Error: No ppx driver were found. It seems that ppx_other is not compatible with Dune. Examples of ppx rewriters that are compatible with Dune are ones using ocaml-migrate-parsetree, ppxlib or ppx_driver. + Leaving directory 'driver-tests' [1] Incompatible Cookies @@ -49,6 +52,7 @@ Incompatible Cookies ^^^^^^^^^^^^^^^ Error: foo.ppx3 and foo.ppx4 have inconsistent requests for cookie "germany"; foo.ppx3 requests "spritzgeback" and foo.ppx4 requests "lebkuchen" + Leaving directory 'driver-tests' [1] Same, but with error pointing to .ppx @@ -56,11 +60,13 @@ Same, but with error pointing to .ppx $ dune build --root driver-tests .ppx/foo.ppx1+foo.ppx2/ppx.exe Entering directory 'driver-tests' Error: invalid ppx key for _build/default/.ppx/foo.ppx1+foo.ppx2/ppx.exe + Leaving directory 'driver-tests' [1] $ dune build --root driver-tests .ppx/foo.ppx-other/ppx.exe Entering directory 'driver-tests' Error: invalid ppx key for _build/default/.ppx/foo.ppx-other/ppx.exe + Leaving directory 'driver-tests' [1] Test the argument syntax @@ -90,6 +96,7 @@ Test the argument syntax 95 | -foo bar %{env:ENGLAND=undefined}))) Error: Rule failed to generate the following targets: - test_ppx_args.pp.ml + Leaving directory 'driver-tests' [1] Test the argument syntax with list expansion allowed (dune > 3.2) @@ -123,6 +130,7 @@ Test the argument syntax with list expansion allowed (dune > 3.2) 24 | -foo bar %{env:ENGLAND=undefined} %{read-lines:ppx-args}))) Error: Rule failed to generate the following targets: - test_ppx_args.pp.ml + Leaving directory 'driver-tests-list-args' [1] Test that going through the -ppx option of the compiler works @@ -131,11 +139,13 @@ Test that going through the -ppx option of the compiler works Entering directory 'driver-tests' tool name: ocamlc args:--as-ppx -arg1 -arg2 -arg3=Oreo -foo bar Snickerdoodle --cookie france="Petit Beurre" --cookie italy="Biscotti" --cookie library-name="test_ppx_staged" + Leaving directory 'driver-tests' Test using installed drivers $ dune build --root driver @install Entering directory 'driver' + Leaving directory 'driver' $ OCAMLPATH=driver/_build/install/default/lib dune build --root use-external-driver driveruser.cma Entering directory 'use-external-driver' .ppx/35d69311d5da258d073875db2b34f33b/ppx.exe @@ -155,6 +165,7 @@ Test using installed drivers ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Error: Rule failed to generate the following targets: - driveruser.pp.ml + Leaving directory 'use-external-driver' [1] $ OCAMLPATH=driver/_build/install/default/lib dune build --root replaces driveruser.cma @@ -177,10 +188,12 @@ Test using installed drivers ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Error: Rule failed to generate the following targets: - driveruser.pp.ml + Leaving directory 'replaces' [1] $ OCAMLPATH=driver/_build/install/default/lib dune build --root driver-replaces @install Entering directory 'driver-replaces' + Leaving directory 'driver-replaces' $ OCAMLPATH=driver/_build/install/default/lib:driver-replaces/_build/install/default/lib dune build --root replaces-external driveruser.cma Entering directory 'replaces-external' replacesdriver @@ -201,4 +214,5 @@ Test using installed drivers ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Error: Rule failed to generate the following targets: - driveruser.pp.ml + Leaving directory 'replaces-external' [1] diff --git a/test/blackbox-tests/test-cases/dune-project-meta/main.t/run.t b/test/blackbox-tests/test-cases/dune-project-meta/main.t/run.t index 7c9fbe62b2d0..b3d35c5b80e7 100644 --- a/test/blackbox-tests/test-cases/dune-project-meta/main.t/run.t +++ b/test/blackbox-tests/test-cases/dune-project-meta/main.t/run.t @@ -43,6 +43,7 @@ The `dune build` should generate the opam file $ dune build @install --root test1 Entering directory 'test1' + Leaving directory 'test1' $ cat test1/cohttp.opam # This file is generated by dune, edit dune-project instead @@ -105,6 +106,7 @@ Fatal error with opam file that is not listed in the dune-project file: the dune-project file. Since you have at least one other (package ...) stanza in your dune-project file, you must a (package ...) stanza for each opam package in your project. + Leaving directory 'test1' [1] Package information fields can be overridden per-package: @@ -131,6 +133,7 @@ Package information fields can be overridden per-package: $ dune build @install --root test2 Entering directory 'test2' + Leaving directory 'test2' $ cat test2/foo.opam # This file is generated by dune, edit dune-project instead @@ -190,6 +193,7 @@ generated META and opam files. $ dune build --root version foo.opam META.foo Entering directory 'version' + Leaving directory 'version' $ grep ^version version/foo.opam version: "1.0" @@ -225,6 +229,7 @@ generated META and opam files. $ dune build --root version foo.opam META.foo Entering directory 'version' + Leaving directory 'version' $ grep ^version version/foo.opam version: "1.0" @@ -245,6 +250,7 @@ Generation of opam files with lang dune >= 1.11 $ dune build @install --root gen-v1.11 Entering directory 'gen-v1.11' + Leaving directory 'gen-v1.11' $ cat gen-v1.11/test.opam # This file is generated by dune, edit dune-project instead opam-version: "2.0" @@ -287,6 +293,7 @@ sorted in a way that pleases "opam lint". > EOF $ dune build @install --root template Entering directory 'template' + Leaving directory 'template' $ tail -n 1 template/foo.opam x-foo: "blah" @@ -295,6 +302,7 @@ sorted in a way that pleases "opam lint". > EOF $ dune build @install --root template Entering directory 'template' + Leaving directory 'template' $ tail -n 1 template/foo.opam libraries: [ "blah" ] @@ -303,6 +311,7 @@ sorted in a way that pleases "opam lint". > EOF $ dune build @install --root template Entering directory 'template' + Leaving directory 'template' $ tail -n 1 template/foo.opam depends: [ "overridden" ] @@ -329,6 +338,7 @@ Not supported before 2.1: ^^^^^^^^^^^^^^ Error: Passing two arguments to <> is only available since version 2.1 of the dune language. Please update your dune-project file to have (lang dune 2.1). + Leaving directory 'binops' [1] Supported since 2.1: @@ -344,6 +354,7 @@ Supported since 2.1: $ dune build @install --root binops Entering directory 'binops' + Leaving directory 'binops' $ grep conf-libX11 binops/foo.opam "conf-libX11" {os != "win32"} diff --git a/test/blackbox-tests/test-cases/dup-fields.t/run.t b/test/blackbox-tests/test-cases/dup-fields.t/run.t index e22193a2f148..fb6b62f04b05 100644 --- a/test/blackbox-tests/test-cases/dup-fields.t/run.t +++ b/test/blackbox-tests/test-cases/dup-fields.t/run.t @@ -6,4 +6,5 @@ Duplicating a field in a dune file is an error: 4 | (action (echo bar))) ^^^^^^^^^^^^^^^^^^^ Error: Field "action" is present too many times + Leaving directory 'dune' [1] diff --git a/test/blackbox-tests/test-cases/duplicate-c-cxx-obj.t/run.t b/test/blackbox-tests/test-cases/duplicate-c-cxx-obj.t/run.t index 65598f18ae2d..31af5b526199 100644 --- a/test/blackbox-tests/test-cases/duplicate-c-cxx-obj.t/run.t +++ b/test/blackbox-tests/test-cases/duplicate-c-cxx-obj.t/run.t @@ -16,6 +16,7 @@ stubs names, things are still broken if their .o files overlap: definition at dune:9. Hint: You can avoid the name clash by renaming one of the objects, or by placing it into a different directory. + Leaving directory 'diff-stanza' Another form of this bug is if the same source is present in different directories. In this case, the rules are fine, but this is probably not what the @@ -28,6 +29,7 @@ user intended. ^^^^^^^ Error: Relative part of stub is not necessary and should be removed. To include sources in subdirectories, use the (include_subdirs ...) stanza. + Leaving directory 'same-stanza' [1] $ cat >same-stanza/dune < 2.5 it is a warning ocaml_version and context_name variables are allowed in this 'enabled_if' field. If you think that project_root should also be allowed, please file an issue about it. + Leaving directory 'forbidden_var' bar For dune >= 2.6 it is an error @@ -63,6 +66,7 @@ For dune >= 2.6 it is an error ocaml_version and context_name variables are allowed in this 'enabled_if' field. If you think that project_root should also be allowed, please file an issue about it. + Leaving directory 'forbidden_var' [1] @@ -77,6 +81,7 @@ For dune < 2.7 context_name is not allowed ^^^^^^^^^^^^^^^ Error: %{context_name} is only available since version 2.7 of the dune language. Please update your dune-project file to have (lang dune 2.7). + Leaving directory 'var_context_name' [1] For dune >= 2.7 context_name allowed @@ -85,6 +90,7 @@ For dune >= 2.7 context_name allowed > EOF $ dune exec ./foo.exe --root var_context_name Entering directory 'var_context_name' + Leaving directory 'var_context_name' bar For dune >= 3.2, negating expressions is allowed @@ -102,4 +108,5 @@ For dune >= 3.2, negating expressions is allowed > EOF $ dune exec ./foo.exe --root negated Entering directory 'negated' + Leaving directory 'negated' runs diff --git a/test/blackbox-tests/test-cases/exec-cmd.t/run.t b/test/blackbox-tests/test-cases/exec-cmd.t/run.t index 5e6d2e0485dc..20f34462b7ab 100644 --- a/test/blackbox-tests/test-cases/exec-cmd.t/run.t +++ b/test/blackbox-tests/test-cases/exec-cmd.t/run.t @@ -23,6 +23,7 @@ $ (cd test; dune exec --root .. -- dunetestbar) Entering directory '..' + Leaving directory '..' Bar $ ls -a test/_build diff --git a/test/blackbox-tests/test-cases/exes-with-c.t/run.t b/test/blackbox-tests/test-cases/exes-with-c.t/run.t index 145a671b2979..cacd678d301a 100644 --- a/test/blackbox-tests/test-cases/exes-with-c.t/run.t +++ b/test/blackbox-tests/test-cases/exes-with-c.t/run.t @@ -21,4 +21,5 @@ 4 | (foreign_stubs (language c) (names stubs))) Error: Pure bytecode executables cannot contain foreign stubs. Hint: If you only need to build a native executable use "(modes exe)". + Leaving directory 'err' [1] diff --git a/test/blackbox-tests/test-cases/fallback-dune.t/run.t b/test/blackbox-tests/test-cases/fallback-dune.t/run.t index 31dae32d5e7e..5c5ae9b94e39 100644 --- a/test/blackbox-tests/test-cases/fallback-dune.t/run.t +++ b/test/blackbox-tests/test-cases/fallback-dune.t/run.t @@ -7,6 +7,7 @@ fallback isn't allowed in dune ^^^^^^^^^^ Error: 'fallback' was renamed to '(mode fallback)' in the 1.0 version of the dune language + Leaving directory 'dune1' [1] 2nd fallback form isn't allowed either @@ -18,4 +19,5 @@ fallback isn't allowed in dune ^^^^^^^^^^^^^^^^ Error: 'fallback' was renamed to '(mode fallback)' in the 1.0 version of the dune language + Leaving directory 'dune2' [1] diff --git a/test/blackbox-tests/test-cases/findlib-error.t/run.t b/test/blackbox-tests/test-cases/findlib-error.t/run.t index 746b84471208..2b50abc5b9ea 100644 --- a/test/blackbox-tests/test-cases/findlib-error.t/run.t +++ b/test/blackbox-tests/test-cases/findlib-error.t/run.t @@ -7,4 +7,5 @@ We are dropping support for findlib in dune ^^^^^^^^^^^^^^ Error: %{findlib:..} was renamed to '%{lib:..}' in the 1.0 version of the dune language + Leaving directory 'in-dune' [1] diff --git a/test/blackbox-tests/test-cases/foreign-library.t b/test/blackbox-tests/test-cases/foreign-library.t index 929ca89c4fde..a6e6d098c94d 100644 --- a/test/blackbox-tests/test-cases/foreign-library.t +++ b/test/blackbox-tests/test-cases/foreign-library.t @@ -743,6 +743,7 @@ Testsuite for the (foreign_library ...) stanza. $ export OCAMLPATH=$PWD/external/install/lib; ./sdune exec ./main.exe --root=some/dir Entering directory 'some/dir' + Leaving directory 'some/dir' Answer = 42 ---------------------------------------------------------------------------------- @@ -791,6 +792,7 @@ Testsuite for the (foreign_library ...) stanza. 2 | (archive_name some/path/id) ^^^^^^^^^^^^ Error: Path separators are not allowed in archive names. + Leaving directory 'github2914/dir' [1] ---------------------------------------------------------------------------------- @@ -902,5 +904,6 @@ Testsuite for the (foreign_library ...) stanza. > EOF $ dune build --root stubs_in_libs Entering directory 'stubs_in_libs' + Leaving directory 'stubs_in_libs' $ stubs_in_libs/_build/default/main.exe 12 diff --git a/test/blackbox-tests/test-cases/github1099.t/run.t b/test/blackbox-tests/test-cases/github1099.t/run.t index 9c0074b24a76..25cbaf6b2382 100644 --- a/test/blackbox-tests/test-cases/github1099.t/run.t +++ b/test/blackbox-tests/test-cases/github1099.t/run.t @@ -6,6 +6,7 @@ If the source directory does not exist, an error message is printed: 1 | (copy_files# "no_dir/*") ^^^^^^^^^^ Error: Cannot find directory: no_dir + Leaving directory 'no-dir' [1] This works also is a file exists with the same name: @@ -16,4 +17,5 @@ This works also is a file exists with the same name: 1 | (copy_files# "no_dir/*") ^^^^^^^^^^ Error: Cannot find directory: no_dir + Leaving directory 'file-with-same-name' [1] diff --git a/test/blackbox-tests/test-cases/github1549.t/run.t b/test/blackbox-tests/test-cases/github1549.t/run.t index f5506f078ff3..a666c1578f88 100644 --- a/test/blackbox-tests/test-cases/github1549.t/run.t +++ b/test/blackbox-tests/test-cases/github1549.t/run.t @@ -2,6 +2,7 @@ Reproduction case for #1549: too many parentheses in installed .dune files $ dune build @install --root backend Entering directory 'backend' + Leaving directory 'backend' $ dune_cmd cat backend/_build/install/default/lib/dune_inline_tests/dune-package | sed "s/(lang dune .*)/(lang dune )/" | dune_cmd sanitize (lang dune ) @@ -45,3 +46,4 @@ Reproduction case for #1549: too many parentheses in installed .dune files $ env OCAMLPATH=backend/_build/install/default/lib dune runtest --root example Entering directory 'example' + Leaving directory 'example' diff --git a/test/blackbox-tests/test-cases/github1616.t/run.t b/test/blackbox-tests/test-cases/github1616.t/run.t index 4cea9ff4f1e8..3d405271edb4 100644 --- a/test/blackbox-tests/test-cases/github1616.t/run.t +++ b/test/blackbox-tests/test-cases/github1616.t/run.t @@ -3,3 +3,4 @@ Regression test for #1616 $ env PATH="$PWD/bin2:$PWD/bin1:$PATH" dune build --root root Entering directory 'root' Hello, World! + Leaving directory 'root' diff --git a/test/blackbox-tests/test-cases/ignored_subdirs.t/run.t b/test/blackbox-tests/test-cases/ignored_subdirs.t/run.t index 3ff9bb834e62..f804d54f0f39 100644 --- a/test/blackbox-tests/test-cases/ignored_subdirs.t/run.t +++ b/test/blackbox-tests/test-cases/ignored_subdirs.t/run.t @@ -1,12 +1,17 @@ $ dune build --root pre-1.6 data/dune Entering directory 'pre-1.6' + Leaving directory 'pre-1.6' $ dune build --root pre-1.6 @all Entering directory 'pre-1.6' + Leaving directory 'pre-1.6' $ dune build --root 1.6 @runtest Entering directory '1.6' real dir + Leaving directory '1.6' $ dune build --root glob @runtest Entering directory 'glob' real dir + Leaving directory 'glob' $ dune build --root logical @runtest Entering directory 'logical' + Leaving directory 'logical' diff --git a/test/blackbox-tests/test-cases/inline_tests/dune-file.t/run.t b/test/blackbox-tests/test-cases/inline_tests/dune-file.t/run.t index 1baaf505cfc5..03e36b923b3e 100644 --- a/test/blackbox-tests/test-cases/inline_tests/dune-file.t/run.t +++ b/test/blackbox-tests/test-cases/inline_tests/dune-file.t/run.t @@ -28,3 +28,4 @@ package: $ export OCAMLPATH=$PWD/_install/lib; dune runtest --root dune-file-user Entering directory 'dune-file-user' 414243 + Leaving directory 'dune-file-user' diff --git a/test/blackbox-tests/test-cases/inline_tests/executable-flags.t/run.t b/test/blackbox-tests/test-cases/inline_tests/executable-flags.t/run.t index 6a14023cf24b..e8ee5bde8b6c 100644 --- a/test/blackbox-tests/test-cases/inline_tests/executable-flags.t/run.t +++ b/test/blackbox-tests/test-cases/inline_tests/executable-flags.t/run.t @@ -7,6 +7,7 @@ to be successful. $ dune runtest valid_options --root ./test-project Entering directory 'test-project' backend_foo + Leaving directory 'test-project' Lastly, we pass an invalid option to flags field expecting compilation to fail. diff --git a/test/blackbox-tests/test-cases/instrumentation.t/run.t b/test/blackbox-tests/test-cases/instrumentation.t/run.t index 3c32f3e0d4e3..abb7e19f6eca 100644 --- a/test/blackbox-tests/test-cases/instrumentation.t/run.t +++ b/test/blackbox-tests/test-cases/instrumentation.t/run.t @@ -187,5 +187,6 @@ Next, we check the backend can be used when it is installed. > EOF $ OCAMLPATH=$PWD/_install/lib:$OCAMLPATH dune build --root installed Entering directory 'installed' + Leaving directory 'installed' $ installed/_build/default/main.exe Hello from Main! diff --git a/test/blackbox-tests/test-cases/intf-only.t/run.t b/test/blackbox-tests/test-cases/intf-only.t/run.t index 475e65d7ebdc..4dfed3602b9a 100644 --- a/test/blackbox-tests/test-cases/intf-only.t/run.t +++ b/test/blackbox-tests/test-cases/intf-only.t/run.t @@ -17,6 +17,7 @@ Successes: ocamlopt test/bar.{a,cmxa} ocamlopt foo.cmxs ocamlopt test/bar.cmxs + Leaving directory 'foo' Errors: @@ -29,6 +30,7 @@ Errors: You need to add the following field to this stanza: (modules_without_implementation x y) + Leaving directory 'a' [1] $ dune build --root b foo.cma Entering directory 'b' @@ -38,6 +40,7 @@ Errors: Error: The following modules must be listed here as they don't have an implementation: - Y + Leaving directory 'b' [1] $ dune build --root c foo.cma Entering directory 'c' @@ -45,6 +48,7 @@ Errors: 3 | (modules_without_implementation x)) ^ Error: Module X doesn't exist. + Leaving directory 'c' [1] $ dune build --root d foo.cma Entering directory 'd' @@ -54,4 +58,5 @@ Errors: Error: The following modules have an implementation, they cannot be listed as modules_without_implementation: - X + Leaving directory 'd' [1] diff --git a/test/blackbox-tests/test-cases/lib.t b/test/blackbox-tests/test-cases/lib.t index 0f643fdee633..aa0a9f45b3fa 100644 --- a/test/blackbox-tests/test-cases/lib.t +++ b/test/blackbox-tests/test-cases/lib.t @@ -177,6 +177,7 @@ Testsuite for the %{lib...} and %{lib-private...} variable. Error: The variable "lib-private" can only refer to libraries within the same project. The current project's name is "test-lib", but the reference is to an external library. + Leaving directory 'src' [1] ---------------------------------------------------------------------------------- diff --git a/test/blackbox-tests/test-cases/libexec.t b/test/blackbox-tests/test-cases/libexec.t index e9172ca00793..bb154fef34e0 100644 --- a/test/blackbox-tests/test-cases/libexec.t +++ b/test/blackbox-tests/test-cases/libexec.t @@ -202,6 +202,7 @@ Testsuite for the %{libexec...} and %{libexec-private...} variable. Error: The variable "libexec-private" can only refer to libraries within the same project. The current project's name is "test-lib", but the reference is to an external library. + Leaving directory 'src' [1] $ export OCAMLPATH=$PWD/external/install/lib; ./sdune build @find-a-from-target --root=src --workspace=./dune-workspace @@ -212,6 +213,7 @@ Testsuite for the %{libexec...} and %{libexec-private...} variable. Error: The variable "libexec-private" can only refer to libraries within the same project. The current project's name is "test-lib", but the reference is to an external library. + Leaving directory 'src' [1] ---------------------------------------------------------------------------------- diff --git a/test/blackbox-tests/test-cases/link-includes.t b/test/blackbox-tests/test-cases/link-includes.t index 537d56efbf17..8d765cb3f9ef 100644 --- a/test/blackbox-tests/test-cases/link-includes.t +++ b/test/blackbox-tests/test-cases/link-includes.t @@ -20,6 +20,7 @@ Test linktime includes for an external library with C stubs > EOF $ dune build --root lib1 @install Entering directory 'lib1' + Leaving directory 'lib1' First we create an external library and implementation $ mkdir exe @@ -34,5 +35,6 @@ First we create an external library and implementation Then we make sure that it works fine. $ env OCAMLPATH=lib1/_build/install/default/lib: dune exec --root exe ./bar.exe Entering directory 'exe' + Leaving directory 'exe' lib1: 42 diff --git a/test/blackbox-tests/test-cases/meta-template-version-bug.t b/test/blackbox-tests/test-cases/meta-template-version-bug.t index 21cbdf81bddb..12c09f3fa742 100644 --- a/test/blackbox-tests/test-cases/meta-template-version-bug.t +++ b/test/blackbox-tests/test-cases/meta-template-version-bug.t @@ -47,4 +47,5 @@ custom version: $ OCAMLPATH=$PWD/_install/lib dune exec --root external ./main.exe Entering directory 'external' + Leaving directory 'external' foobarlib diff --git a/test/blackbox-tests/test-cases/missing-loc-run.t/run.t b/test/blackbox-tests/test-cases/missing-loc-run.t/run.t index b3727f0df9a9..4dc92346685c 100644 --- a/test/blackbox-tests/test-cases/missing-loc-run.t/run.t +++ b/test/blackbox-tests/test-cases/missing-loc-run.t/run.t @@ -4,6 +4,7 @@ Exact path provided by the user: Entering directory 'precise-path' Error: No rule found for foo.exe -> required by alias runtest in dune:1 + Leaving directory 'precise-path' [1] Path that needs to be searched: @@ -15,6 +16,7 @@ Path that needs to be searched: ^^^^^^^^^^^^^^^^^^ Error: Program foo-does-not-exist not found in the tree or in PATH (context: default) + Leaving directory 'search-path' [1] Path in deps field of alias stanza @@ -23,4 +25,5 @@ Path in deps field of alias stanza Entering directory 'alias-deps-field' Error: No rule found for foobar -> required by alias runtest in dune:1 + Leaving directory 'alias-deps-field' [1] diff --git a/test/blackbox-tests/test-cases/no-installable-mode.t/run.t b/test/blackbox-tests/test-cases/no-installable-mode.t/run.t index 56b781488d4f..37e83afd7b12 100644 --- a/test/blackbox-tests/test-cases/no-installable-mode.t/run.t +++ b/test/blackbox-tests/test-cases/no-installable-mode.t/run.t @@ -13,6 +13,7 @@ message is displayed: - exe - native - byte + Leaving directory 'public' [1] However, it is possible to build a private one explicitly. @@ -23,6 +24,7 @@ However, it is possible to build a private one explicitly. ocamlc .myprivatelib.eobjs/byte/myprivatelib.{cmi,cmo,cmt} ocamlopt .myprivatelib.eobjs/native/myprivatelib.{cmx,o} ocamlopt myprivatelib$ext_dll + Leaving directory 'private' Byte_complete is allowed to be installable since 3.6 diff --git a/test/blackbox-tests/test-cases/ocamldep-multi-stanzas.t/run.t b/test/blackbox-tests/test-cases/ocamldep-multi-stanzas.t/run.t index a496dd5af927..fa546d9e35e5 100644 --- a/test/blackbox-tests/test-cases/ocamldep-multi-stanzas.t/run.t +++ b/test/blackbox-tests/test-cases/ocamldep-multi-stanzas.t/run.t @@ -8,6 +8,7 @@ library, executable, and executables stanzas in this dune file. Note that each module cannot appear in more than one "modules" field - it must belong to a single library or executable. + Leaving directory 'dune' [1] $ dune build src/a.cma --debug-dep --root dune @@ -20,4 +21,5 @@ library, executable, and executables stanzas in this dune file. Note that each module cannot appear in more than one "modules" field - it must belong to a single library or executable. + Leaving directory 'dune' [1] diff --git a/test/blackbox-tests/test-cases/old-dune-subsystem.t/run.t b/test/blackbox-tests/test-cases/old-dune-subsystem.t/run.t index bc3133c00b28..cc30e824df16 100644 --- a/test/blackbox-tests/test-cases/old-dune-subsystem.t/run.t +++ b/test/blackbox-tests/test-cases/old-dune-subsystem.t/run.t @@ -13,4 +13,5 @@ we understand the old files. 3 | (inline_tests (backend dune_inline_tests))) ^^^^^^^^^^^^^^^^^ Error: dune_inline_tests is not an inline tests backend + Leaving directory 'example' [1] diff --git a/test/blackbox-tests/test-cases/path-variables.t/run.t b/test/blackbox-tests/test-cases/path-variables.t/run.t index ac07dcd760ea..7c05d050aea7 100644 --- a/test/blackbox-tests/test-cases/path-variables.t/run.t +++ b/test/blackbox-tests/test-cases/path-variables.t/run.t @@ -8,7 +8,7 @@ In expands to a file name, and registers this as a dependency. $ dune build --root dune @test-dep Entering directory 'dune' - dynamic-contents + dynamic-contentsLeaving directory 'dune' %{path-no-dep:string} --------------------- @@ -25,4 +25,5 @@ This form does not exist, but displays an hint: 8 | (echo "%{path-no-dep:.}\n"))))) ^^^^^^^^^^^^^^^^ Error: %{path-no-dep:..} was deleted in version 1.0 of the dune language. + Leaving directory 'dune-invalid' [1] diff --git a/test/blackbox-tests/test-cases/private-package-lib/main.t b/test/blackbox-tests/test-cases/private-package-lib/main.t index 804c27eda98a..53722a2ded72 100644 --- a/test/blackbox-tests/test-cases/private-package-lib/main.t +++ b/test/blackbox-tests/test-cases/private-package-lib/main.t @@ -157,6 +157,7 @@ Now we make sure such libraries are transitively usable when installed: $ export OCAMLPATH=$PWD/_build/install/default/lib $ dune exec --root use -- ./run.exe Entering directory 'use' + Leaving directory 'use' Using library foo: from library foo secret string But we cannot use such libraries directly: @@ -170,4 +171,5 @@ But we cannot use such libraries directly: 1 | print_endline ("direct access attempt: " ^ Secret.secret) ^^^^^^^^^^^^^ Error: Unbound module Secret + Leaving directory 'use' [1] diff --git a/test/blackbox-tests/test-cases/quoting.t/run.t b/test/blackbox-tests/test-cases/quoting.t/run.t index bfa53dfb0e89..aa30fee86392 100644 --- a/test/blackbox-tests/test-cases/quoting.t/run.t +++ b/test/blackbox-tests/test-cases/quoting.t/run.t @@ -8,6 +8,7 @@ that ${@} is not quoted and doesn't contain exactly 1 element ^^^^^^^^^^ Error: Variable %{targets} expands to 2 values, however a single value is expected here. Please quote this atom. + Leaving directory 'bad' [1] The targets should only be interpreted as a single path when quoted @@ -21,15 +22,17 @@ The targets should only be interpreted as a single path when quoted Error: Rule failed to generate the following targets: - s - t + Leaving directory 'good' [1] $ dune runtest --root quote-from-context Entering directory 'quote-from-context' Number of args: 3 + Leaving directory 'quote-from-context' $ dune runtest --root quotes-multi Entering directory 'quotes-multi' - lines: foo bar baz + lines: foo bar bazLeaving directory 'quotes-multi' $ dune build @quoted --root filename-space Entering directory 'filename-space' @@ -37,6 +40,7 @@ The targets should only be interpreted as a single path when quoted 4 | (action (echo %{read:foo bar.txt}))) ^ Error: This character is not allowed inside %{...} forms + Leaving directory 'filename-space' [1] $ dune build @unquoted --root filename-space @@ -45,4 +49,5 @@ The targets should only be interpreted as a single path when quoted 4 | (action (echo %{read:foo bar.txt}))) ^ Error: This character is not allowed inside %{...} forms + Leaving directory 'filename-space' [1] diff --git a/test/blackbox-tests/test-cases/re-exported-deps.t/run.t b/test/blackbox-tests/test-cases/re-exported-deps.t/run.t index 7e8102c484ef..2b9f5795ab24 100644 --- a/test/blackbox-tests/test-cases/re-exported-deps.t/run.t +++ b/test/blackbox-tests/test-cases/re-exported-deps.t/run.t @@ -1,11 +1,13 @@ dependencies can be exported transitively: $ dune exec ./foo.exe --root transitive Entering directory 'transitive' + Leaving directory 'transitive' transitive deps expressed in the dune-package $ dune build @install --root transitive Entering directory 'transitive' + Leaving directory 'transitive' $ dune_cmd cat transitive/_build/install/default/lib/pkg/dune-package | sed "s/(lang dune .*)/(lang dune )/" | dune_cmd sanitize (lang dune ) (name pkg) @@ -73,4 +75,5 @@ Re-exporting deps in executables isn't allowed 7 | (libraries (re_export foo))) ^^^^^^^^^^^^^^^ Error: re_export is not allowed here + Leaving directory 're-export-exe' [1] diff --git a/test/blackbox-tests/test-cases/reason.t/run.t b/test/blackbox-tests/test-cases/reason.t/run.t index 5cdd11a847f9..5a1c7396976e 100644 --- a/test/blackbox-tests/test-cases/reason.t/run.t +++ b/test/blackbox-tests/test-cases/reason.t/run.t @@ -24,3 +24,4 @@ We make sure to install reason source files: virtual libraries in reason $ PATH="_build/install/default/bin:$PATH" dune build --root vlib-impl @all Entering directory 'vlib-impl' + Leaving directory 'vlib-impl' diff --git a/test/blackbox-tests/test-cases/rule-target-inferrence.t/run.t b/test/blackbox-tests/test-cases/rule-target-inferrence.t/run.t index e271edb782ab..ac27cbd0b9cf 100644 --- a/test/blackbox-tests/test-cases/rule-target-inferrence.t/run.t +++ b/test/blackbox-tests/test-cases/rule-target-inferrence.t/run.t @@ -3,13 +3,13 @@ This works with the short form of the rule stanza: $ dune build @infer --root short-form Entering directory 'short-form' - It worked! + It worked!Leaving directory 'short-form' But should work with the long form as well: $ dune build @infer --root long-form Entering directory 'long-form' - It should work as well! + It should work as well!Leaving directory 'long-form' When an action has no targets, an helpful error message is displayed: @@ -19,6 +19,7 @@ When an action has no targets, an helpful error message is displayed: 1 | (rule (action (echo "something"))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Error: Rule has no targets specified + Leaving directory 'no-target' [1] When the rule action targets cannot be inferred by dune, we should make it explicit @@ -30,4 +31,5 @@ in the error message: 1 | (rule (action (system "something"))) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Error: Rule has no targets specified + Leaving directory 'cannot-infer' [1] diff --git a/test/blackbox-tests/test-cases/rule/dependency-external.t b/test/blackbox-tests/test-cases/rule/dependency-external.t index ccaf0c5f7af6..b833ab68c7b7 100644 --- a/test/blackbox-tests/test-cases/rule/dependency-external.t +++ b/test/blackbox-tests/test-cases/rule/dependency-external.t @@ -22,9 +22,11 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt1 + Leaving directory 'a/b' $ dune build --root=a/b @test Entering directory 'a/b' + Leaving directory 'a/b' $ cat >external.txt < txt2 @@ -33,6 +35,7 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt2 + Leaving directory 'a/b' ## Test copy files absolute $ cat >a/b/dune <external.txt < txt2 @@ -61,6 +66,7 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt2 + Leaving directory 'a/b' ### 1 level below @@ -78,10 +84,12 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt1 + Leaving directory 'a/b' # Check that nothing is done when nothing change $ dune build --root=a/b @test Entering directory 'a/b' + Leaving directory 'a/b' $ cat >a/external.txt < txt2 @@ -90,6 +98,7 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt2 + Leaving directory 'a/b' ## Test copy files 1 level below $ cat >a/b/dune <a/external.txt < txt2 @@ -118,6 +129,7 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt2 + Leaving directory 'a/b' ### 2 level below @@ -137,10 +149,12 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt1 + Leaving directory 'a/b' # Check that nothing is done when nothing change $ dune build --root=a/b @test Entering directory 'a/b' + Leaving directory 'a/b' $ cat >external.txt < txt2 @@ -149,6 +163,7 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt2 + Leaving directory 'a/b' ## Test copy files 2 level below $ cat >a/b/dune <external.txt < txt2 @@ -177,6 +194,7 @@ rules with dependencies outside the build dir are allowed $ dune build --root=a/b @test Entering directory 'a/b' txt2 + Leaving directory 'a/b' ## Test dune exec absolute $ cat >a/script.sh < EOF $ dune build --root external @install Entering directory 'external' + Leaving directory 'external' $ mkdir test $ echo "(lang dune 2.5)" > test/dune-project $ cat >test/dune < EOF $ dune build --root 2.3 target | head -c1 Entering directory '2.3' + Leaving directory '2.3' $ dune_cmd stat permissions 2.3/_build/default/target | head -c1 6 @@ -47,6 +48,7 @@ Check that dune >= 2.4 removes target write permissions. > EOF $ dune build --root 2.4 foo.exe @install Entering directory '2.4' + Leaving directory '2.4' $ dune_cmd stat permissions 2.4/_build/default/foo.exe | head -c1 5 $ dune install --root 2.4 --prefix ./ @@ -56,6 +58,7 @@ Check that dune >= 2.4 removes target write permissions. Installing bin/foo Installing bin/foo.exe Installing share/foo/target + Leaving directory '2.4' $ dune_cmd stat permissions 2.4/bin/foo.exe | head -c1 7 $ dune_cmd stat permissions 2.4/share/foo/target | head -c1