X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F10_10informix_common.t;h=6ebd0a21f64a4b9a23889904cd4c81427cab1c98;hb=3b7ea110ea6e400d497b05e8e366db10e30abfdb;hp=aada1ea981bfb7a59dced168e3a729e5d9dac460;hpb=e8c7b904425c1f61a1d48ff2a294b9faf7d12b8f;p=dbsrgits%2FDBIx-Class-Schema-Loader.git diff --git a/t/10_10informix_common.t b/t/10_10informix_common.t index aada1ea..6ebd0a2 100644 --- a/t/10_10informix_common.t +++ b/t/10_10informix_common.t @@ -1,3 +1,6 @@ +use DBIx::Class::Schema::Loader::Optional::Dependencies + -skip_all_without => 'test_rdbms_informix'; + use strict; use warnings; use Test::More; @@ -27,7 +30,7 @@ my $password = $ENV{DBICTEST_INFORMIX_PASS} || ''; my ($schema, $extra_schema); # for cleanup in END for extra tests -my $tester = dbixcsl_common_tests->new( +dbixcsl_common_tests->new( vendor => 'Informix', auto_inc_pk => 'serial primary key', null => '', @@ -63,9 +66,9 @@ my $tester = dbixcsl_common_tests->new( numeric => { data_type => 'numeric' }, decimal => { data_type => 'numeric' }, dec => { data_type => 'numeric' }, - 'numeric(6,3)' => { data_type => 'numeric', size => [6,3] }, - 'decimal(6,3)' => { data_type => 'numeric', size => [6,3] }, - 'dec(6,3)' => { data_type => 'numeric', size => [6,3] }, + 'numeric(6,3)' => { data_type => 'numeric', size => [6,3] }, + 'decimal(6,3)' => { data_type => 'numeric', size => [6,3] }, + 'dec(6,3)' => { data_type => 'numeric', size => [6,3] }, # Boolean Type # XXX this should map to 'boolean' @@ -206,7 +209,7 @@ EOF push @warns, $_[0] unless $_[0] =~ /\bcollides\b/ || $_[0] =~ /unreferencable/; }; - + make_schema_at( 'InformixMultiDatabase', { @@ -330,14 +333,7 @@ EOF } }, }, -); - -if( !$dsn ) { - $tester->skip_tests('You need to set the DBICTEST_INFORMIX_DSN, _USER, and _PASS environment variables'); -} -else { - $tester->run_tests(); -} +)->run_tests(); sub db_name { my $schema = shift; @@ -368,7 +364,7 @@ END { } if (my $dbh1 = try { $schema->storage->dbh }) { - + try { $dbh1->do('DROP TABLE informix_loader_test5'); $dbh1->do('DROP TABLE informix_loader_test4');