lilypond-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unit testing


From: Chris Yate
Subject: Re: Unit testing
Date: Sun, 30 Oct 2016 00:57:47 +0000

On Sat, 29 Oct 2016 at 20:32 Urs Liska <address@hidden> wrote:

>
> That's what I thought, and that's of course a good thing. But would it be
> conceivable to actually start doing unit tests? One should probably not be
> frightened by the issue that we won't be able to apply that backwardly, to
> the existing code.
>
> Urs
>
>
It's an excellent idea Urs; and I for one feel very uneasy writing code
without a test framework.

I think the problem is, how would you define an assertion, and what are you
intending to test (i.e. what's the Subject Under Test?). I think something
like Lilypond might require some quite elaborate test fixtures / fakes.

There are probably C++ functions you could test with a C++ assert based
test framework - Catch for example - or something simpler.  Obviously
anything doing a bit of maths is easy to test; the interesting functions
tend to manipulate "Grob" objects; would the tests be examining their
properties after the function call?

But what about Scheme code?...

Chris


reply via email to

[Prev in Thread] Current Thread [Next in Thread]