diff --git a/test/blackbox-tests/test-cases/quoting/bad/dune b/test/blackbox-tests/test-cases/quoting/bad/dune new file mode 100644 index 00000000..5920e9ae --- /dev/null +++ b/test/blackbox-tests/test-cases/quoting/bad/dune @@ -0,0 +1,3 @@ +(rule + ((targets (x y)) + (action (with-stdout-to ${@} (echo foo))))) \ No newline at end of file diff --git a/test/blackbox-tests/test-cases/quoting/dune b/test/blackbox-tests/test-cases/quoting/dune deleted file mode 100644 index 648656a6..00000000 --- a/test/blackbox-tests/test-cases/quoting/dune +++ /dev/null @@ -1,3 +0,0 @@ -(rule - ((targets (x y)) - (action (with-stdout-to ${@} (echo foo))))) diff --git a/test/blackbox-tests/test-cases/quoting/good/dune b/test/blackbox-tests/test-cases/quoting/good/dune new file mode 100644 index 00000000..ba9c28f6 --- /dev/null +++ b/test/blackbox-tests/test-cases/quoting/good/dune @@ -0,0 +1,3 @@ +(rule + ((targets (s t)) + (action (with-stdout-to "${@}" (echo foo))))) \ No newline at end of file diff --git a/test/blackbox-tests/test-cases/quoting/run.t b/test/blackbox-tests/test-cases/quoting/run.t index 41161049..5bfd5e4d 100644 --- a/test/blackbox-tests/test-cases/quoting/run.t +++ b/test/blackbox-tests/test-cases/quoting/run.t @@ -1,9 +1,15 @@ This behavior is surprising, we should get an error about the fact that ${@} is not quoted and doesn't contain exactly 1 element - $ dune build x + $ dune build --root bad x 2>&1 | grep -v Entering Error: Rule failed to generate the following targets: - x - y - [1] + +The targets should only be interpreted as a single path when quoted + + $ dune build --root good s 2>&1 | grep -v Entering + Error: Rule failed to generate the following targets: + - s + - t