This post originated from an RSS feed registered with Ruby Buzz
by Daniel Berger.
Original Post: Maybe -t isn't the answer
Feed Title: Testing 1,2,3...
Feed URL: http://djberg96.livejournal.com/data/rss
Feed Description: A blog on Ruby and other stuff.
I recently submitted a feature request for Rubygems to run with -t (run tests) by default. Because, hey, we're test obsessed right? Maybe it's not such a wise idea, though.
Dave Rolsky points out a problem with running tests by default when installing modules via the CPAN shell in the world of Perl:
Perl has a great culture of testing. We expect all modules uploaded to CPAN to come with a test suite, and we expect modules to run their tests on install and to pass. I love that we have such high standards, but these standards are not without problems. When a module fails its tests, the person doing the install isn't in a good position to handle it. In many cases, they could probably force the install and use the module, but how could they know that?
In the comments Perrin Harkin points out:
Running the tests in the CPAN shell before every module install was never very realistic and gets less so every day. I remember back in the early days of working with mod_perl, when the Perl testing culture was not that strong. I would find modules didn't install with the CPAN shell because the tests were written in a way that would never run on any computer except the author's. When I told authors about this, they would say "Oh, I've never used the CPAN shell. I just install modules in the normal way."
No one does that anymore, because the dependency chains are now too long and annoying to do manually. We have to use the CPAN shell. (Or make alternative packaging of some kind, but that's a different story.) So, CPAN.pm should stop running the tests. Either they should be off by default, or it should be obvious how to turn them off globally. If someone is having trouble with a module, they can go run the tests then.
Simply turning off the tests in the CPAN shell would make installing Moose a reasonable thing and do away with nearly all griping about dependencies.