X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fcdbi-t%2F26-mutator.t;fp=t%2Fcdbi-t%2F26-mutator.t;h=0000000000000000000000000000000000000000;hb=50891152d0b24649bfd67bdba97feec86b11c064;hp=1eeea2511c9857f6414c5a7ce076c62ea43e0e5e;hpb=23209c4474d71e419b3fcf9699ae05565c2997f5;p=dbsrgits%2FDBIx-Class.git diff --git a/t/cdbi-t/26-mutator.t b/t/cdbi-t/26-mutator.t deleted file mode 100644 index 1eeea25..0000000 --- a/t/cdbi-t/26-mutator.t +++ /dev/null @@ -1,47 +0,0 @@ -use strict; -use Test::More; - -BEGIN { - eval "use DBIx::Class::CDBICompat;"; - plan skip_all => "Class::Trigger and DBIx::ContextualFetch required: $@" - if $@; -} - -BEGIN { - eval "use DBD::SQLite"; - plan $@ - ? (skip_all => 'needs DBD::SQLite for testing') - : (tests => 6); -} - -use lib 't/testlib'; -require Film; - -sub Film::accessor_name_for { - my ($class, $col) = @_; - return "sheep" if lc $col eq "numexplodingsheep"; - return $col; -} - -my $data = { - Title => 'Bad Taste', - Director => 'Peter Jackson', - Rating => 'R', -}; - -my $bt; -eval { - my $data = $data; - $data->{sheep} = 1; - ok $bt = Film->insert($data), "Modified accessor - with -accessor"; - isa_ok $bt, "Film"; -}; -is $@, '', "No errors"; - -eval { - ok $bt->sheep(2), 'Modified accessor, set'; - ok $bt->update, 'Update'; -}; -is $@, '', "No errors"; -