On Fri, 16 Jul 2004, Dirk Gerrits wrote:
My problem is how to use any such testing framework /effectively/. The style of writing a bit of code in the REPL, trying it out, and copying it to my file, editing it a bit, trying it out in the REPL again... is comfortable for me.
FWIW.
I never type any code I'm likely to want to keep into the REPL. If there's a place for it it goes into the appropriate file, if not I tend to keep around a scratch.lisp buffer for stuff like that. Then I either C-x C-e or C-c C-c it.
In the REPL I only do very ephemeral stuff: tweaking FORMAT expressions, munging files, using it as a desktop calculator, REQUIRE'ing stuff, etc.
For tests I typically use the RT framework, and have a test-op for the system the tests are for. To run all the tests I just do (in the REPL):
(oos 'test-op :foo)
and when working on a single case I may edit & recompile the relevant code & tests, and then just rerun those ones from the REPL:
(rt:do-test 'foo-tests:frob.42)
Cheers,
-- Nikodemus "Not as clumsy or random as a C++ or Java. An elegant weapon for a more civilized time."