Added support for test and benchmark documentation with Haddock.

See #1357