Silently ignores tests, when inline_tests is not specified (ppx_custom_printf)
Nobody has claimed this yet.
- Dominant language
- OCaml
- Stars
- 1.9k
- Forks
- 500
- Avg merge
- 15h 17m
- Merged PRs (30d)
- 287
Description
I am not sure if it is really possible to fix, or it is one of the design constrains. Please fill free to close with Will-Not-Fix.
While exploring ppx_custom_printf rewriter, I found that dune build @runtest command does almost nothing for this package (checked with strace). However, tests are written. Quite soon, it revealed that test/dune file missed mandatory inline_tests stanza. See https://github.com/janestreet/ppx_custom_printf/issues/5
The problem is that tests were silently ignored. So, the developer would think mistakenly that they have passed (after fix they passed indeed).
I don't think that there is a good solution for this problem. But, as a semi-solution dune can warn, if absolutely no tests were executed for runtest target. This definitely will not hurt.
Or, may be, dune can dump the list of executed tests? Painted in emerald green, of course.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing dune build @runtest for the ppx_custom_printf case and inspect the mentioned test/dune file, including its missing inline_tests stanza. Review the linked issue for context, then determine whether Dune should warn when runtest executes no tests or report the executed test list; done requires a defined behavior and coverage for the chosen approach.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ocaml
- Domain
- build-system, testing-qa
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100