Skip to content

Commit

Permalink
[t/lib] diagnostics while initializing test db
Browse files Browse the repository at this point in the history
  • Loading branch information
moritz committed Jun 21, 2011
1 parent 265eed4 commit b2d83e4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions t/lib/Quelology/Test/Setup.pm
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
use 5.010;
package Quelology::Test::Setup;
use strict;
use warnings;
Expand All @@ -15,7 +16,9 @@ sub init_db {
# TODO: read that info from the config file
my ($user, $dbname, $host) = map config($_), qw/dbuser dbname dbhost/;

say '# initilizing test db... this might take a while';
system("psql $dbname -h $host -U $user < t/db-snapshot.sql > /dev/null 2>&1");
say '# ... done initilizing test db.';
}

1;

0 comments on commit b2d83e4

Please sign in to comment.