Check truth of preserve_case not definedness
[dbsrgits/DBIx-Class-Schema-Loader.git] / t / 30_03no_comment_table.t
1 use strict;
2 use warnings;
3 use Test::More;
4 use Test::Exception;
5 use Test::Warn;
6 use DBIx::Class::Schema::Loader::Utils 'slurp_file';
7 use File::Path;
8 use lib qw(t/lib);
9 use make_dbictest_db;
10 use dbixcsl_test_dir qw/$tdir/;
11
12 my $dump_path = "$tdir/dump";
13
14 {
15     package DBICTest::Schema::1;
16     use base qw/ DBIx::Class::Schema::Loader /;
17     __PACKAGE__->loader_options(
18         dump_directory => $dump_path,
19         quiet => 1,
20     );
21 }
22
23 DBICTest::Schema::1->connect($make_dbictest_db::dsn);
24
25 plan tests => 1;
26
27 my $foo = slurp_file("$dump_path/DBICTest/Schema/1/Result/Foo.pm");
28 my $bar = slurp_file("$dump_path/DBICTest/Schema/1/Result/Bar.pm");
29
30 like($foo, qr/Result::Foo\n/, 'No error from lack of comment tables');
31
32 END { rmtree($dump_path, 1, 1); }