X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fcdbi%2F11-triggers.t;h=c944248426ec18aceb874188e33bc8dc051094a5;hb=26aea721d0dd94fe9920efa3c01f081642399c28;hp=37c179cf32a984bd95462df03034913cfba0a4e5;hpb=68de943862f06cabd397d2e74d12cd9cdc999779;p=dbsrgits%2FDBIx-Class.git diff --git a/t/cdbi/11-triggers.t b/t/cdbi/11-triggers.t index 37c179c..c944248 100644 --- a/t/cdbi/11-triggers.t +++ b/t/cdbi/11-triggers.t @@ -1,15 +1,7 @@ use strict; +use warnings; use Test::More; -BEGIN { - eval "use DBIx::Class::CDBICompat;"; - if ($@) { - plan (skip_all => 'Class::Trigger and DBIx::ContextualFetch required'); - next; - } - plan tests => 13; -} - use lib 't/cdbi/testlib'; use Film; @@ -57,9 +49,11 @@ is + ( ok $ver->delete, "Delete"; { - Film->add_trigger(before_create => sub { + Film->add_trigger(before_create => sub { my $self = shift; ok !$self->_attribute_exists('title'), "PK doesn't auto-vivify"; }); Film->create({director => "Me"}); } + +done_testing;