Switch the main dev branch back to 'master'
[dbsrgits/DBIx-Class.git] / t / cdbi / set_vs_DateTime.t
CommitLineData
54a9a088 1use DBIx::Class::Optional::Dependencies -skip_all_without => qw( ic_dt cdbicompat );
83eef562 2
e60dc79f 3use strict;
4a233f30 4use warnings;
83eef562 5
e60dc79f 6use Test::More;
4c9f72c1 7use Test::Exception;
d9bd5195 8
97d61088 9use lib 't/cdbi/testlib';
e60dc79f 10
11{
12 package Thing;
13
97d61088 14 use base 'DBIC::Test::SQLite';
e60dc79f 15
16 Thing->columns(All => qw[thing_id this that date]);
17}
18
19my $thing = Thing->construct({ thing_id => 23, date => "01-02-1994" });
4c9f72c1 20my $date = DateTime->now;
21lives_ok {
22 $thing->set( date => $date );
23 $thing->set( date => $date );
e60dc79f 24};
4c9f72c1 25
e60dc79f 26$thing->discard_changes;
d9bd5195 27
28done_testing;