Version 2.008001
[catagits/Catalyst-Controller-DBIC-API.git] / t / lib / RestTest / Controller / API / REST / Artist.pm
CommitLineData
d2739840 1package RestTest::Controller::API::REST::Artist;
2use Moose;
3BEGIN { extends 'Catalyst::Controller::DBIC::API::REST' }
4use namespace::autoclean;
5
6__PACKAGE__->config
7 ( action => { setup => { PathPart => 'artist', Chained => '/api/rest/rest_base' } },
8 class => 'RestTestDB::Artist',
9 create_requires => ['name'],
10 create_allows => ['name'],
11 update_allows => ['name'],
12 prefetch_allows => [[qw/ cds /],{ 'cds' => 'tracks'}],
13 );
14
68e02291 15sub action_with_error : Chained('objects_no_id') PathPart('action_with_error') Args(0) {
16 my ( $self, $c ) = @_;
17
18 $c->res->status(404);
19}
20
d2739840 211;