1 use DBIx::Class::Optional::Dependencies -skip_all_without => 'cdbicompat';
8 use lib 't/cdbi/testlib';
11 package # hide from PAUSE
14 use base 'DBIC::Test::SQLite';
17 __PACKAGE__->set_table('Movies');
18 __PACKAGE__->columns(All => qw(id title));
22 id INTEGER PRIMARY KEY AUTOINCREMENT,
28 my $film = MyFilm->create({ title => "For Your Eyes Only" });
31 my $new_film = $film->copy;
33 isnt $new_film->id, $film->id, "copy() gets new primary key";
35 $new_film = $film->copy(42);
36 is $new_film->id, 42, "copy() with new id";