[darcs-users] darcs testing script question...

David Brown darcs at davidb.org
Fri Apr 9 15:32:15 UTC 2004


On Fri, Apr 09, 2004 at 07:05:20AM -0400, David Roundy wrote:

> Hmmmm.  Basically all we have in darcs is step three.  Implementing steps 1
> and 2 would obviously require separating the test suite from the code
> itself in some way, since you'd have to be able to change the two
> independently.  This can be challenging/annoying to do in darcs.

Aegis keeps track of this.  It has a list of 'normal' file and 'test'
files.  The normal mode in Aegis, is that the tests are merely scripts
that are run when CD'd to the previous version (the baseline).  There
are some workarounds to actually build against it, but it doesn't fit as
cleanly with what Aegis is trying to do.

> If you trust your developers, you could expect them to create separate
> patches for test code and for actual code.  Then you'd just need to be able
> to invert the results of the test (it would be easy to add a darcs flag to
> do this).  Then the test could first be recorded using an
> --expect-failed-test flag, followed by the code change itself, which would
> be expected to pass the test.  It's a bit clumsy.

Aegis doesn't require that every change have tests that fail against the
baseline.  It doesn't even require that each change have tests.  It is
specified per-test.  The main different is that in Aegis, the changes
are described before they are implemented.  It can even be configured so
that different people are responsible for creating the changes, than the
developers who make them.

I have found the model to be helpful for some tasks.  I've also found
that the overhead needed to make a normal build system fit into its
model to be burdensome.  One advantage to darcs is that it is so easy to
create an archive.  All that is needed is the ability to create a
directory somewhere.

Dave Brown




More information about the darcs-users mailing list