delete Core::View and ResultSourceProxy::View, fix ResultSource::View
[dbsrgits/DBIx-Class.git] / t / lib / DBICTest / Schema / Year2000CDs.pm
CommitLineData
a648ec78 1package # hide from PAUSE
2 DBICTest::Schema::Year2000CDs;
3
030c27ad 4use base 'DBIx::Class::Core';
5use DBIx::Class::ResultSource::View;
a648ec78 6
030c27ad 7__PACKAGE__->table_class('DBIx::Class::ResultSource::View');
8
9__PACKAGE__->table('cd');
10__PACKAGE__->result_source_instance->view_definition(
11 "SELECT cdid, artist, title FROM cd WHERE year ='2000'"
12);
a648ec78 13__PACKAGE__->add_columns(
14 'cdid' => {
15 data_type => 'integer',
16 is_auto_increment => 1,
17 },
18 'artist' => {
19 data_type => 'integer',
20 },
21 'title' => {
22 data_type => 'varchar',
23 size => 100,
24 },
25
26);
27__PACKAGE__->set_primary_key('cdid');
28__PACKAGE__->add_unique_constraint([ qw/artist title/ ]);
29
301;