On Fri, Jan 07, 2011 at 08:37:12PM +0000, Barbie wrote: > On Fri, Jan 07, 2011 at 06:40:26AM -0500, David Golden wrote: > > I'm co-maintaining HTTP::Tiny and writing tests for it. I'm > > considering adding some simple "live" HTTP client queries (e.g. > > against google.com) but don't want to prompt users for it and don't > > want to connect out to the internet without permission. > > Therefore, I'm considering having those live tests run only when under > > AUTOMATED_TESTING (protected by a check to confirm that the internet > > is accessible, of course). Does that seem reasonable to people? > I'd say that was a tricky one. If the main point of the module is to use > an internet connection, only running those tests under AUTOMATED_TESTING > means a general user may install your module without running tests that > could have shown that there was a problem with their particular > environment.
If the concern is privacy, then perhaps have it ask as part of Makefile.PL, but skip the question and just go ahead under AUTOMATED_TESTING. > If they are simple connection tests, that I would think you should be > fine. Any complex then running under AUTOMATED_TESTING is reasonable, > and prompting (default to No) otherwise. Perhaps do a simple check for connectivity and have it skip the more complex tests if that doesn't work. Naturally, you should do the connectivity test using raw Socket.pm so as not to introduce any dependencies :-) -- David Cantrell | Godless Liberal Elitist EINE KIRCHE! EIN KREDO! EIN PAPST!