X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F30_02bad_comment_table.t;h=bee64f9bf0222918d55b5641695636fc71488611;hb=a79e11896d6d1d70842c432cde8830ded06568ce;hp=ec0eda6eebc27fadd34eb378415fa877107afa1e;hpb=2db2c8982208e6d6e74bd673158277cdabd5c2a1;p=dbsrgits%2FDBIx-Class-Schema-Loader.git diff --git a/t/30_02bad_comment_table.t b/t/30_02bad_comment_table.t index ec0eda6..bee64f9 100644 --- a/t/30_02bad_comment_table.t +++ b/t/30_02bad_comment_table.t @@ -1,13 +1,14 @@ use strict; +use warnings; use Test::More; use Test::Exception; use Test::Warn; -use lib qw(t/lib); -use File::Slurp qw(slurp); +use DBIx::Class::Schema::Loader::Utils 'slurp_file'; use File::Path; +use Try::Tiny; +use lib qw(t/lib); use make_dbictest_db_bad_comment_tables; use dbixcsl_test_dir qw/$tdir/; -use Try::Tiny; my $dump_path = "$tdir/dump"; @@ -26,8 +27,8 @@ try { plan tests => 1; -my $foo = try { slurp("$dump_path/DBICTest/Schema/1/Result/Foo.pm") }; -my $bar = try { slurp("$dump_path/DBICTest/Schema/1/Result/Bar.pm") }; +my $foo = try { slurp_file("$dump_path/DBICTest/Schema/1/Result/Foo.pm") }; +my $bar = try { slurp_file("$dump_path/DBICTest/Schema/1/Result/Bar.pm") }; like($foo, qr/Result::Foo\n/, 'No error from invalid comment tables');