1 BEGIN { do "./t/lib/ANFANG.pm" or die ( $@ || $! ) }
11 my $schema = DBICTest->init_schema();
12 $schema->storage->sql_maker->quote_char('"');
14 my $rs = $schema->resultset ('Artist');
17 lives_ok { $obj = $rs->create ({ name => 'artistA' }) } 'Default insert successful';
18 is ($obj->rank, undef, 'Without retrieve_on_insert, check rank');
20 $rs->result_source->add_columns(
21 '+rank' => { retrieve_on_insert => 1 }
24 lives_ok { $obj = $rs->create ({ name => 'artistB' }) } 'Default insert successful';
25 is ($obj->rank, 13, 'With retrieve_on_insert, check rank');