Re: capturing carp()s in module tests?

2004-02-19 Thread Rodent of Unusual Size
Smylers wrote: > > Indeed it would be irritating for people to have to install a module > just so they can test your module. But that's no reason to skip the > test for those who do have it installed. > > Couldn't you put in a conditional test that only executes if require-ing > Test::Warn succe

Re: capturing carp()s in module tests?

2004-02-19 Thread Smylers
Rodent of Unusual Size writes: > Adrian Howard wrote: > > > Test::Warn should do the job: > > > > use Test::Warn; > > warnings_like { carp "Danger! Danger!" } qr/^Danger! Danger!/; > > unfortunately, it doesn't appear to be a default part of > a vanilla 5.6 installation, and i'm loath to requir

Re: capturing carp()s in module tests?

2004-02-18 Thread David Manura
Rodent of Unusual Size wrote: Adrian Howard wrote: Test::Warn should do the job: use Test::Warn; warnings_like { carp "Danger! Danger!" } qr/^Danger! Danger!/; unfortunately, it doesn't appear to be a default part of a vanilla 5.6 installation, and i'm loath to require a module used only during

Re: capturing carp()s in module tests?

2004-02-18 Thread Rodent of Unusual Size
Adrian Howard wrote: > > Test::Warn should do the job: > > use Test::Warn; > warnings_like { carp "Danger! Danger!" } qr/^Danger! Danger!/; unfortunately, it doesn't appear to be a default part of a vanilla 5.6 installation, and i'm loath to require a module used only during installation. but t

Re: capturing carp()s in module tests?

2004-02-17 Thread Adrian Howard
On Tuesday, February 17, 2004, at 03:28 am, Rodent of Unusual Size wrote: i want to test error checks in a module i'm working on. the error paths carp() the problem and then proceed. is there any way to capture the carp text (without using some of Carp.pm's internal routines) for testing that t

RE: capturing carp()s in module tests?

2004-02-17 Thread Orton, Yves
Title: RE: capturing carp()s in module tests? > i want to test error checks in a module i'm working on.  the > error paths carp() the problem and then proceed. > > is there any way to capture the carp text (without using > some of Carp.pm's internal routines)