in reply to What to test for in a module that returns a DB handle?
Many of the DBI modules ... and, I believe, DBI itself ... include some tests within their test-suite which do test connectivity. Those tests are generally defined to be optional. (For instance, I don’t think that the pre-install test-list that is run by the cpan command mandatorily executes them, but if you want to run the tests yourself, you can choose to include them.)
These tests, IIRC, require that a particular database-name be defined, with a particular user-id and password that has full-privilege to that database. For testing purposes only. And they very-exhaustively test the correct operation of the package.
I suppose that the ruling assumption is that “the author of the module did run those tests. (And CPANTS probably does, too.)” Such that individual client sites, realistically speaking, don’t have to do so unless they particularly want to. That seems like a well-balanced compromise to me, and I suggest that you do the same.