Reorganize runmode detection a bit
[dbsrgits/DBIx-Class.git] / xt / notabs.t
1 use warnings;
2 use strict;
3
4 use Test::More;
5 use lib 't/lib';
6 use DBICTest;
7
8 # Don't run tests for installs
9 if ( DBICTest::RunMode->is_plain ) {
10   plan( skip_all => "Author tests not required for installation" );
11 }
12
13 require DBIx::Class;
14 unless ( DBIx::Class::Optional::Dependencies->req_ok_for ('test_notabs') ) {
15   my $missing = DBIx::Class::Optional::Dependencies->req_missing_for ('test_notabs');
16   (! DBICTest::RunMode->is_plain && ! DBICTest::RunMode->is_smoker )
17     ? die ("Failed to load release-testing module requirements: $missing")
18     : plan skip_all => "Test needs: $missing"
19 }
20
21 Test::NoTabs::all_perl_files_ok(
22   qw/t xt lib script/,
23   DBICTest::RunMode->is_author ? ('maint') : (),
24 );
25
26 # FIXME - need to fix Test::NoTabs - doesn't work with done_testing
27 #done_testing;