{ # crash the connect() my $ok = eval { App::RPi::EnvUI::DB->new( db_file => '/' ); 1; }; is $ok, undef, "when a DBH can't be created, we die"; like $@, qr/unable to open database/, "...and the error message is sane"; } { # good connect() my $db = App::RPi::EnvUI::DB->new( testing => 1 ); is ref $db->{db}, 'DBI::db', "dbh loaded ok"; }