cons-discuss
[Top][All Lists]
Advanced

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

Re: Ctrl-C on Win32


From: Johan Holmberg
Subject: Re: Ctrl-C on Win32
Date: Mon, 23 Apr 2001 20:40:48 +0200 (MEST)

On Mon, 23 Apr 2001, Steven Knight wrote:
> >
> > I have tested my ideas with 5.6 and it seem to work as expected,
> > but I don't know how to write a testcase for it (especially the
> > timing-dependent part).
>
> This is a fun one for building a test case...  Here's an outline of how
> I'd do it:
>
> [detailed decription removed]

Wow, that was even more complicated than I imagined, with lots of
potentially platform-dependent functionality (fork/
background process/kill/sleep ....).


> [...]  The script should build the target
> file, but also sleep(), say for three seconds.  This will be when you'll
> interrupt Cons (avoiding timing issues).
>

The case I thought about as most tricky to test was to send the
signal (Ctrl-C) while Cons was *not* running another command (via
system), ie. when Cons was running its own code.
When I tested this manually I added a "busy-wait" loop to the Cons
source, but I guess it has to be done another way to be usable as a
real testcase. Can a [perl] rule be used, or isn't that realistic
enough ???

/Johan Holmberg





reply via email to

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