throw_exception if view_definition is missing instead of silent skipping + test changes
[dbsrgits/DBIx-Class.git] / lib / SQL / Translator / Parser / DBIx / Class.pm
index 40389b3..c8235e3 100644 (file)
@@ -289,7 +289,8 @@ EOW
         # Its possible to have multiple DBIC source using same table
         next if $views{$view_name}++;
 
-        next unless $source->view_definition;
+        $dbicschema->throw_exception ("view $view_name is missing a view_definition")
+            unless $source->view_definition;
 
         my $view = $schema->add_view (
           name => $view_name,