Remove leftover Devel::Dwarn from test
[dbsrgits/DBIx-Class-Schema-Loader.git] / t / 10_03pg_common.t
index 1d392dd..b1ab020 100644 (file)
@@ -82,6 +82,7 @@ dbixcsl_common_tests->new(
         # Bit String Types
         'bit varying(2)' => { data_type => 'varbit', size => 2 },
         'varbit(2)'      => { data_type => 'varbit', size => 2 },
+        'bit varying'    => { data_type => 'varbit' },
         'varbit'         => { data_type => 'varbit' },
         bit              => { data_type => 'bit', size => 1 },
         'bit(3)'         => { data_type => 'bit', size => 3 },
@@ -293,7 +294,7 @@ dbixcsl_common_tests->new(
             'DROP VIEW pg_loader_test11',
         ],
         drop  => [ qw/pg_loader_test1 pg_loader_test2 pg_loader_test9 pg_loader_test10 pg_loader_test12/ ],
-        count => 10 + 30 * 2,
+        count => 11 + 30 * 2,   # regular + multi-schema * 2
         run   => sub {
             my ($schema, $monikers, $classes) = @_;
 
@@ -489,8 +490,13 @@ dbixcsl_common_tests->new(
             }
 
             # test that views are marked as such
-            isa_ok $schema->resultset($monikers->{pg_loader_test11})->result_source, 'DBIx::Class::ResultSource::View',
-                'views have table_class set correctly';
+            my $view_source = $schema->resultset($monikers->{pg_loader_test11})->result_source;
+            isa_ok $view_source, 'DBIx::Class::ResultSource::View',
+                'view result source';
+
+            like $view_source->view_definition,
+                qr/\A \s* select\b .* \bfrom \s+ pg_loader_test1 \s* \z/imsx,
+                'view definition';
 
             is_deeply
                 { $schema->source($monikers->{pg_loader_test12})->unique_constraints },