Skip to content

test(clean): demonstrate that clean rejects source directories (#2288) - #15300

Merged
rgrinberg merged 1 commit into
mainfrom
test-2288-clean-rejects-source-dirs
Jun 24, 2026
Merged

test(clean): demonstrate that clean rejects source directories (#2288)#15300
rgrinberg merged 1 commit into
mainfrom
test-2288-clean-rejects-source-dirs

Conversation

@rgrinberg

Copy link
Copy Markdown
Member

Reproduces #2288: dune clean does not accept source directories (or package
names) the way dune build/dune runtest do — it only accepts paths inside
the build directory (a capability added in #13875).

This adds a test to clean.t documenting the current behaviour:

  • dune build sub accepts the source directory
  • dune clean sub fails with Error: sub is not inside the build directory
  • dune clean . fails likewise

No behaviour change — the test pins the status quo so it will flip to the
desired output if/when dune clean learns to accept source directories.

🤖 Generated with Claude Code

Document the limitation from #2288: unlike `dune build`, `dune clean` does
not accept a source directory (or package name) — it only accepts paths
inside the build directory. `dune build sub` works, but `dune clean sub` and
`dune clean .` fail with "<path> is not inside the build directory".

This pins the current behaviour; the expected output will flip once `dune
clean` learns to accept source directories.

Signed-off-by: Rudi Grinberg <me@rgrinberg.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@rgrinberg
rgrinberg merged commit 56b3225 into main Jun 24, 2026
28 of 30 checks passed
@rgrinberg
rgrinberg deleted the test-2288-clean-rejects-source-dirs branch June 24, 2026 12:00
@Alizter Alizter added this to the 3.25.0 milestone Jul 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants