[plt-scheme] Re: General advice on what to use for unit testing

From: Matt Jadud (jadudm at gmail.com)
Date: Sun Nov 23 20:49:38 EST 2008

On Sun, Nov 23, 2008 at 4:58 PM, Ernie Smith <esmith at acanac.net> wrote:
> options which can cover the range of circumstances, including across
> different versions of PLT scheme, across different scheme implementations,
> across different developments and target environments, and across different
> size of project.

Can you be more precise? Because in the Scheme world, that particular
list of requirements usually ends with a request for a pony, too. Or
world peace. (In short, you've already set yourself up to fail, unless
you're a very competent, dedicated Scheme developer with broad
experience across all of the implementations you intend to support.)

Do you want to support PLT v103 through 4.1.3? Or, do you mean just
v372 and HEAD? Or, do you mean PLT Scheme from now until some point in
the future?

Do you want to support *any* Scheme implementation, or just Scheme48
and PLT? (Insert your implementation list here, basically.)

Do you want your tests to run in POSIX-compliant environments, or are
you including embedded targets (where there are few Scheme
implementations, but you intend to go there regardless)?

If you want your project to take finite time, then I recommend you
pick one Scheme that does what you need in all the environments you
intend to support, and stick with it. Then, how to do testing is a
much easier question. If you want to multiply the support effort, pick
multiple Scheme implementations and figure out what the intersection
of functionality is that you can use (basically, R5RS). You'll spend a
significant amount of time writing portability wrappers for basic
functionality, and you can probably use SRFI-78 as a bootstrap for
testing.

> In a nutshell I'm seeking any insight or advice I can get on
> choosing a testing strategy and tools that may avoid me having to backtrack
> bad choices later.

In PLT Scheme, use SchemeUnit. Library versions may bite you if you
expect to support old and new versions of PLT Scheme. SRFI-78 may get
you started elsewhere... and possibly even a pony.

Good luck.

Cheers,
Matt


Posted on the users mailing list.