Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^3: Sharing configuration information among test files

by jbert (Priest)
on Aug 15, 2008 at 15:59 UTC ( #704567=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Sharing configuration information among test files
in thread Sharing configuration information among test files

You can put the duplicated code in a module (as you would in non-test code). Then your test scripts can look like:

use Test::More; use MyApp::Frob; use MyApp::Test::Config; my $cfg = MyApp::Test::Config->cfg; my $frob = MyApp::Frob->new($cfg->whoToFrob, $cfg->whatToFrob); ok($frob, "can create a frob");


Comment on Re^3: Sharing configuration information among test files
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://704567]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2014-08-21 04:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (127 votes), past polls