Hadrian test looks a state of tree to determine whether documentation is available
hadrian test
exhibits an rather surprising behavior. Namely, this:
hadrian/build-cabal
hadrian/build-cabal test
and
hadrian/build-cabal
hadrian/build-cabal docs
hadrian/build-cabal test
are not equivalent.
The reason is that Hadrian does not look at the build configuration to determine whether haddock
is available; rather, it checks whether the build documentation files happen to exist. Surprisingly, these are not build during the default build. This means that tests which are marked as req_haddock
do not build unless you first explicitly build the docs
target. This took far too long to discover.