From: Rafael Kitover Date: Sat, 28 Nov 2009 07:44:01 +0000 (+0000) Subject: added test to check for correct file count in common tests X-Git-Tag: 0.04999_11~3 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=1d061ad5e6d24fce667f8641b4950d9ce95d9298;p=dbsrgits%2FDBIx-Class-Schema-Loader.git added test to check for correct file count in common tests --- diff --git a/t/lib/dbixcsl_common_tests.pm b/t/lib/dbixcsl_common_tests.pm index cc9768b..54c4049 100644 --- a/t/lib/dbixcsl_common_tests.pm +++ b/t/lib/dbixcsl_common_tests.pm @@ -56,7 +56,7 @@ sub _monikerize { sub run_tests { my $self = shift; - plan tests => 3 + 135 + ($self->{extra}->{count} || 0); + plan tests => 139 + ($self->{extra}->{count} || 0); $self->create(); @@ -110,7 +110,13 @@ sub setup_schema { __PACKAGE__->connection(\@connect_info); }; - ok(!$@, "Loader initialization") or diag $@; + ok(!$@, "Loader initialization") or diag $@; + + my $file_count; + find sub { return if -d; $file_count++ }, $DUMP_DIR; + + is $file_count, 34, 'correct number of files generated'; + exit if $file_count != 34; my $warn_count = 2; $warn_count++ if grep /ResultSetManager/, @loader_warnings;