I’m trying to get dune to build some long-running tests only when I ask for it explicitly. I have a tests/ directory in which some short-running tests and some long-running tests reside. I can successfully call
dune runtest to build the former ones.
To drive the long-running tests, I created a new alias and rules like so in tests/dune:
(alias (name longtest)) (rule (deps) (action (with-stdout-to longtest1.output (run longtest --test1))) (rule (alias longtest) (action (diff longtest1.expected longtest1.output)))
dune build from a clean state, the long test runs. I then tried to remove the alias
longtest from the default alias by prepending
(alias (name default) (deps (alias runtest)))
in tests/dune. I assumed this would instruct
dune build to only build tests picked up by
@runtest but not the long-running test. This did not appear to work. Where am I wrong?
In general I’m confused as to whether
(alias (name x) (deps ...))) only adds new dependencies or redefines the set of dependencies for