If you have dependencies which are required only by the tests then it is important to flag them as such. If you use ExtUtils::MakeMaker then TEST_REQUIRES is the key. This has the following benefits:
- Users who don't want to run the tests do not end up downloading and installing modules they won't use (ie. if the test dependencies had been declared as main dependencies).
- Users who can't successfully install the test dependencies can still run your module.
- Your tests don't bloat the main code.
FWIW, I agree with Corion and haukex that option 1 is likely to be the best path.