Commit | Line | Data |
762a7bb2 |
1 | use strict; |
2 | use warnings; |
3 | use Test::More; |
4 | |
5 | use lib qw(t/lib); |
762a7bb2 |
6 | |
cc6504dc |
7 | BEGIN { |
748ab0dc |
8 | local $SIG{__WARN__} = sub {}; |
9 | require DBIx::Class::ResultSetManager; |
10 | } |
11 | |
68de9438 |
12 | use DBICTest::ResultSetManager; |
da0d740f |
13 | |
11357d09 |
14 | my $schema = DBICTest::ResultSetManager->compose_namespace('DB'); |
762a7bb2 |
15 | my $rs = $schema->resultset('Foo'); |
16 | |
17 | ok( !DB::Foo->can('bar'), 'Foo class does not have bar method' ); |
18 | ok( $rs->can('bar'), 'Foo resultset class has bar method' ); |
b1fb2c94 |
19 | isa_ok( $rs, 'DBICTest::ResultSetManager::Foo::_resultset', 'Foo resultset class is correct' ); |
cc6504dc |
20 | is( $rs->bar, 'good', 'bar method works' ); |
68de9438 |
21 | |
22 | done_testing; |