X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F40resultsetmanager.t;h=fad560d11a5d8a5fc8a76bc8bb793bb2ae80d548;hb=e1ff35c4815770d1d563a4c1fbdb1cc26772c07a;hp=83892911c00c152495d7599d9fc448a3302073c9;hpb=11357d09a80364da23aefbb5650da15a768505a8;p=dbsrgits%2FDBIx-Class.git diff --git a/t/40resultsetmanager.t b/t/40resultsetmanager.t index 8389291..fad560d 100644 --- a/t/40resultsetmanager.t +++ b/t/40resultsetmanager.t @@ -1,21 +1,17 @@ -#!/usr/bin/perl - use strict; use warnings; use Test::More; +use Test::Warn; use lib qw(t/lib); +use DBICTest; -BEGIN { - eval { require Class::Inspector }; - if ($@ =~ m{Can.t locate Class/Inspector.pm}) { - plan skip_all => "ResultSetManager requires Class::Inspector"; - } else { - plan tests => 4; - } -} - -use DBICTest::ResultSetManager; # uses Class::Inspector +warnings_exist { require DBICTest::ResultSetManager } + [ + qr/\QDBIx::Class::ResultSetManager never left experimental status/, + ], + 'found deprecation warning' +; my $schema = DBICTest::ResultSetManager->compose_namespace('DB'); my $rs = $schema->resultset('Foo'); @@ -24,3 +20,5 @@ ok( !DB::Foo->can('bar'), 'Foo class does not have bar method' ); ok( $rs->can('bar'), 'Foo resultset class has bar method' ); isa_ok( $rs, 'DBICTest::ResultSetManager::Foo::_resultset', 'Foo resultset class is correct' ); is( $rs->bar, 'good', 'bar method works' ); + +done_testing;