friedo has asked for the wisdom of the Perl Monks concerning the following question:
The docs for Test::Class suggest putting your test modules under t/lib. I understand that this will prevent them from being indexed by PAUSE, which is good. My concern arises over including this directory in my test script, t/main.t, which looks like this:
#!/usr/bin/perl # t/main.t -- launch all tests from here use strict; use warnings; use lib './t/lib'; use Test::Class; use MyApp::Test; use MyApp::Foobar::Test; Test::Class->runtests;
This works fine on my system, but I'm worried that the use lib might break on other OSes, especially with the hardcoded relative path. Is there an accepted standard way of doing this which is better?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Test::Class and use lib
by xdg (Monsignor) on Aug 22, 2005 at 10:44 UTC | |
by adrianh (Chancellor) on Aug 22, 2005 at 12:09 UTC | |
|
Re: Test::Class and use lib
by adrianh (Chancellor) on Aug 22, 2005 at 08:16 UTC | |
|
Re: Test::Class and use lib
by fokat (Deacon) on Aug 22, 2005 at 05:11 UTC | |
by adrianh (Chancellor) on Aug 22, 2005 at 08:29 UTC |