![]() |
|
Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Re^2: Setting up a test db with MakeMakerby danmcb (Monk) |
on Feb 25, 2013 at 14:10 UTC ( [id://1020529]=note: print w/replies, xml ) | Need Help?? |
indeed, this works fine. Some code for those that are curious: in t/test_setup.pm:
In a test module
Rather simple in fact. Works fine on 5.10 UPDATE: in fact - I am using this.
And in my Catalyst MyApp.pm class:
Now it is only necessary to "use" test_setup.pm. The setup is executed automatically, and the ENV variable causes the Catalyst app to use another config, which in turn connects to the test database in place of the normal development one.
In Section
Seekers of Perl Wisdom
|
|