I've uploaded a version that works as advertised and runs its test suite
successfully on MSWin32, Cygwin, OpenBSD, and Linux. If you happen to
have a more obscure OS around, I'd love to hear whether or not it
works. (Of course, any other comments are also welcome!)
I'm really not sure of the best way to handle this, so I thought I'd toss this
out to some of you folks.
I recently found out that one of my test programs accidentally sent a bunch of
error email to our support staff. There's often an environment variable named
'HARNESS_ACTIVE' if tests are
From: Yuval Kogman [EMAIL PROTECTED]
What about
$some_object-send_email(@args);
and having your test code:
a. replace the object (probably a singleton or an obj in a
global) with a mock object that doesn't actually send email
b. also test that send_email is being called when
On Tue, Sep 26, 2006 at 06:13:11 -0700, Ovid wrote:
unless ( defined Test::More::ok ) { send_email(@args) }
What about
$some_object-send_email(@args);
and having your test code:
a. replace the object (probably a singleton or an obj in a
global) with a mock object
- Original Message
From: Ovid [EMAIL PROTECTED]
It would be nice if I could just write 'use My::Test::More' in my
test scripts and have that provide what I need
Side note: yes, it's trivial for me to write an extra module which provide an
environment variable or something similar
Ovid wrote:
[snip]
It would be nice if I could just write 'use My::Test::More' in my test
scripts and have that provide what I need, but I'm not sure if trying to
re-export all of the test functions from Test::More (kind of like subclassing
which isn't a class) is a bright idea, but it's
From: Christopher H. Laco [EMAIL PROTECTED]
I'm thinking about doing the same thing. Before Chris Dolan wrote a
Testing::RequireTestLabels policy for me (thanks!), I was going to
subclass Test::More and expose the usual methods and tack on my argument
checking.
Just threw this together and
On Sep 26, 2006, at 8:13 AM, Ovid wrote:
but I think it would be helpful to have something a bit more
reliable (that variable's not set if I just run the tests with
'perl testname.t').
That's one of the nice things about prove, is that you can say prove -
v testname.t and still get
- Original Message
From: Andy Lester [EMAIL PROTECTED]
That's one of the nice things about prove, is that you can say prove -
v testname.t and still get HARNESS_ACTIVE.
Agreed, but when someone forgets and runs the test program directly with
'perl', I can't risk more email being
On 26 Sep 2006, at 14:59, Ovid wrote:
[snip]
(You know, you could probably use that to do interesting things
like caching the last time a given developer ran tests. Hmm, why
anyone want to do that?)
[snip]
So you can do interesting things like run tests in most recently
failed order?
Ovid wrote:
From: Christopher H. Laco [EMAIL PROTECTED]
I'm thinking about doing the same thing. Before Chris Dolan wrote a
Testing::RequireTestLabels policy for me (thanks!), I was going to
subclass Test::More and expose the usual methods and tack on my argument
checking.
Just threw
* Ovid [EMAIL PROTECTED] [2006-09-26T09:19:46]
It would be nice if I could just write 'use My::Test::More' in my
test scripts and have that provide what I need
Side note: yes, it's trivial for me to write an extra module which provide
an environment variable or something similar for this,
In working on CPAN::Reporter, there's been a snag with test.pl files and
ExtUtils::MakeMaker since the Makefile runs test.pl directly instead of
through Test::Harness. Since output is captured with tee to allow user
interaction during tests (if necessary), the exit code is lost. Thus, while
While checking the Wiki page recently pointed to, I noticed that several of
the entries under Producers are actually parsers.
And on the topic of Java, if no one else is working on a Java TAP parser,
I'll step up and see what I can craft.
Randy
--
Randy J. Ray / [EMAIL PROTECTED]
Campbell, CA
14 matches
Mail list logo