use Tests; # ?

2006-07-15 Thread Ovid
Just a thought: use Tests qw/ Exception Differences /; Have it import those modules and check for sub conflicts. By default, it would also provide the Test::More tests but it should also normalize sub behavior: can_ok $proto, $method, $description; isa_ok $instance, $class

Re: use Tests; # ?

2006-07-15 Thread chromatic
gt; > Just doing this: > > use Tests; > > Would import the Test::More equivalents. > > Thoughts? I like everything except overriding the names. I think that would add to the confusion, especially more than a screen length away from the use line. How about different names? -- c

Re: use Tests; # ?

2006-07-15 Thread Michael G Schwern
On 7/15/06, Ovid <[EMAIL PROTECTED]> wrote: Just a thought: use Tests qw/ Exception Differences /; Have it import those modules and check for sub conflicts. This doesn't really buy you anything over: use Test::Exception; use Test::Differences; That already warn

Re: use Tests; # ?

2006-07-17 Thread Ovid
- Original Message From: Michael G Schwern On 7/15/06, Ovid wrote: > > Just a thought: > > > > use Tests qw/ > > Exception > > Differences > > /; > > > > Have it import those modules and check for sub conflicts.

Re: use Tests; # ?

2006-07-17 Thread demerphq
On 7/17/06, Ovid <[EMAIL PROTECTED]> wrote: Many people would prefer that $description always be the last thing you type and always be something you can provide. IMO if I were to write a replacement for Test::More id put the description argument first, and therby make it mandatory. And then yo

Re: use Tests; # ?

2006-07-17 Thread Torsten Schoenfeld
On Mon, 2006-07-17 at 11:39 +0200, demerphq wrote: > Test names shouldnt be optional. I disagree. I would find it cumbersome to have to come up with a description for each and every test. > Finding a particular test in a file by its number can be quite > difficult, especially in test files wher

Re: use Tests; # ?

2006-07-17 Thread demerphq
On 7/17/06, Torsten Schoenfeld <[EMAIL PROTECTED]> wrote: On Mon, 2006-07-17 at 11:39 +0200, demerphq wrote: > Test names shouldnt be optional. I disagree. I would find it cumbersome to have to come up with a description for each and every test. I dont think its that cumbersome at all. Even

Re: use Tests; # ?

2006-07-17 Thread Fergal Daly
On 17/07/06, demerphq <[EMAIL PROTECTED]> wrote: On 7/17/06, Torsten Schoenfeld <[EMAIL PROTECTED]> wrote: > On Mon, 2006-07-17 at 11:39 +0200, demerphq wrote: > > > Test names shouldnt be optional. > > I disagree. I would find it cumbersome to have to come up with a > description for each and e

Re: use Tests; # ?

2006-07-17 Thread demerphq
On 7/17/06, Fergal Daly <[EMAIL PROTECTED]> wrote: On 17/07/06, demerphq <[EMAIL PROTECTED]> wrote: > On 7/17/06, Torsten Schoenfeld <[EMAIL PROTECTED]> wrote: > > On Mon, 2006-07-17 at 11:39 +0200, demerphq wrote: > > > > > Test names shouldnt be optional. > > > > I disagree. I would find it cu

Re: use Tests; # ?

2006-07-17 Thread Fergal Daly
On 17/07/06, demerphq <[EMAIL PROTECTED]> wrote: On 7/17/06, Fergal Daly <[EMAIL PROTECTED]> wrote: > On 17/07/06, demerphq <[EMAIL PROTECTED]> wrote: > > On 7/17/06, Torsten Schoenfeld <[EMAIL PROTECTED]> wrote: > > > On Mon, 2006-07-17 at 11:39 +0200, demerphq wrote: > > > > > > > Test names sh

Re: use Tests; # ?

2006-07-17 Thread chromatic
On Monday 17 July 2006 05:19, demerphq wrote: > The fact that it does the same thing every time for a given set of > input doesnt mean that it does the RIGHT thing. And i dont see how its > possible to automatically do the right thing every time. Therefore if > you need a custom wrapper you need t

Re: use Tests; # ?

2006-07-17 Thread Ovid
- Original Message From: chromatic <[EMAIL PROTECTED]> > On Monday 17 July 2006 05:19, demerphq wrote: > > > The fact that it does the same thing every time for a given set of > > input doesnt mean that it does the RIGHT thing. And i dont see how its > > possible to automatically do the

Re: use Tests; # ?

2006-07-17 Thread Fergal Daly
On 17/07/06, chromatic <[EMAIL PROTECTED]> wrote: On Monday 17 July 2006 11:37, Ovid wrote: > For example, what could be done in TAP::Harness to improve the reporting on > line numbers? That alone would be a nice benefit for folks. I agree, but I disclaim the idea that there's a nice, general,

Re: use Tests; # ?

2006-07-17 Thread chromatic
On Monday 17 July 2006 11:37, Ovid wrote: > For example, what could be done in TAP::Harness to improve the reporting on > line numbers?  That alone would be a nice benefit for folks. I agree, but I disclaim the idea that there's a nice, general, working heuristic. The best I've come up with che

Re: use Tests; # ?

2006-07-17 Thread A. Pagaltzis
* Fergal Daly <[EMAIL PROTECTED]> [2006-07-17 15:45]: > The standard way to do this is to put > > local $Test::Builder::Level = $Test::Builder::Level + 1; > > at the top of every function in your library that does not > actually call ->ok() use Attribute::Handlers; sub UNIVERSAL::TestHe

RE: use Tests; # ?

2006-07-17 Thread leif . eriksen
y, 17 July 2006 7:48 PM To: perl-qa@perl.org Subject: Re: use Tests; # ? On Mon, 2006-07-17 at 11:39 +0200, demerphq wrote: > Test names shouldnt be optional. I disagree. I would find it cumbersome to have to come up with a description for each and every test. > Finding a particular t

Re: use Tests; # ?

2006-07-18 Thread Michael G Schwern
On 7/17/06, demerphq <[EMAIL PROTECTED]> wrote: > Well, if the test passes, there's no need to know where exactly it's > located. If it fails, the diagnostics contain the line number: > > not ok 6 > # Failed test in t/xxx.t at line 26. > > I've never seen incorrect line numbers. I have. L

Re: use Tests; # ?

2006-07-18 Thread Michael G Schwern
On 7/17/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: I know we've moved on, but I'm in a completely different time zone, so please understand... I, like demerphq, also think that coming up with a name for each and every test is a good idea. It shouldn't be hard to think of a description f