[darcs-users] darcs patch: fix tests to sort of work with hpc.

David Roundy droundy at darcs.net
Thu Oct 2 21:49:13 UTC 2008

Hi all,

This is a patch that I'm probably going to stop working on myself, but
which I'd be delighted if someone else were to make work.  It (almost)
makes the darcs test suite able to work with hpc, Haskell Program
Coverage.  This is a really cool but extremely awkard feature of ghc
that tracks which expressions and which functions are run, so we could
see how thorough our test suite is, and get a good idea as to what
functions we might want to add new tests for.

The trouble is that it always dumps its output in the working
directory in which darcs is called.  Since the test suite cleans up
after itself, this makes it awkward to get the coverage data out.  The
approach I tried in this patch is to create a wrapper that calls darcs
and then rescues the data.

It almost works, but doesn't really, as I can see that the coverage
sometimes drops as the test suite is run.  Debugging it is really not
a good use of my time, and the best and simplest option would probably
be to fix ghc to allow you to configure the directory in which the
darcs.tix data is dumped (e.g. by an environment variable).


Thu Oct  2 17:42:39 EDT 2008  David Roundy <droundy at darcs.net>
  * fix tests to sort of work with hpc.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: text/x-darcs-patch
Size: 32316 bytes
Desc: A darcs patch for your repository!
Url : http://lists.osuosl.org/pipermail/darcs-users/attachments/20081002/5a46b1ff/attachment-0001.bin 

More information about the darcs-users mailing list