Update version
[dbsrgits/DBIx-Class.git] / t / 40resultsetmanager.t
CommitLineData
762a7bb2 1#!/usr/bin/perl
2
3use strict;
4use warnings;
5use Test::More;
6
7use lib qw(t/lib);
8use DBICTest::Extra;
9
cc6504dc 10BEGIN {
11 eval "use Class::Inspector";
12 plan $@
13 ? ( skip_all => 'needs Class:Inspector for testing' )
14 : ( tests => 4 );
15}
762a7bb2 16
17my $schema = DBICTest::Extra->compose_connection('DB', 'foo');
18my $rs = $schema->resultset('Foo');
19
20ok( !DB::Foo->can('bar'), 'Foo class does not have bar method' );
21ok( $rs->can('bar'), 'Foo resultset class has bar method' );
22isa_ok( $rs, 'DBICTest::Extra::Foo::_resultset', 'Foo resultset class is correct' );
cc6504dc 23is( $rs->bar, 'good', 'bar method works' );