Re: Flunking tests and failing code

2005-12-06 Thread Luke Palmer
On 12/6/05, chromatic [EMAIL PROTECTED] wrote: On Mon, 2005-12-05 at 07:54 +, Luke Palmer wrote: I wonder if there is a macroey thing that we can do here. That is, could we make: ok(1); is(1, 1); like(foo, /foo/); Into: ok(1); ok(1 == 1);

Re: Flunking tests and failing code

2005-12-06 Thread Luke Palmer
On 12/6/05, Luke Palmer [EMAIL PROTECTED] wrote: That still leaves the problem of what to do with fail() and is() in the compiler suite. Here's a handwavey crack at what I was talking about: Ack. Accidentally sent the half written message. Let's try again: my $comparators = set == eq

Re: Flunking tests and failing code

2005-12-05 Thread Nathan Gray
On Mon, Dec 05, 2005 at 07:54:25AM +, Luke Palmer wrote: I wonder if there is a macroey thing that we can do here. That is, could we make: ok(1); is(1, 1); like(foo, /foo/); Into: ok(1); ok(1 == 1); ok(foo ~~ /foo/); And lexically analyze the argument

Re: Flunking tests and failing code

2005-12-05 Thread Ruud H.G. van Tol
Nathan Gray: Luke Palmer: I wonder if there is a macroey thing that we can do here. That is, could we make: ok(1); is(1, 1); like(foo, /foo/); Into: ok(1); ok(1 == 1); ok(foo ~~ /foo/); And lexically analyze the argument to ok() to find out how to

Re: Flunking tests and failing code

2005-12-05 Thread chromatic
On Mon, 2005-12-05 at 07:54 +, Luke Palmer wrote: I wonder if there is a macroey thing that we can do here. That is, could we make: ok(1); is(1, 1); like(foo, /foo/); Into: ok(1); ok(1 == 1); ok(foo ~~ /foo/); Can you do it without giving up the nice

Flunking tests and failing code

2005-12-04 Thread Gaal Yahas
There's a bikeshedding question of some visibility: now that we have a Cfail builtin, what do we do with CTest::fail? There's plenty of code out there that uses fail as an exported function from pugs' Test.pm or Perl 5 testing modules. We want to keep Test primitives exported and fun to use, to

Re: Flunking tests and failing code

2005-12-04 Thread Luke Palmer
On 12/5/05, Gaal Yahas [EMAIL PROTECTED] wrote: There's a bikeshedding question of some visibility: now that we have a Cfail builtin, what do we do with CTest::fail? Is it possible to do nothing with it? That is, can we coerce the Test module to understand when the main program fails? This