ok (($schema->resultset('Routechange')->find(1)->can('quuxsid')),
'correct column accessor in 0.04006 mode');
+
+ is $schema->resultset('Routechange')->find(1)->foo2bar, 3,
+ 'correct column accessor for column with word ending with digit in v4 mode';
}
sub run_v5_tests {
ok (($schema->resultset('Routechange')->find(1)->can('quuxsid')),
'correct column accessor in v5 mode');
+
+ is $schema->resultset('Routechange')->find(1)->foo2bar, 3,
+ 'correct column accessor for column with word ending with digit in v5 mode';
}
sub run_v6_tests {
ok (($schema->resultset('Routechange')->find(1)->can('quuxsid')),
'correct column accessor in v6 mode');
+
+ is $schema->resultset('Routechange')->find(1)->foo2bar, 3,
+ 'correct column accessor for column with word ending with digit in v6 mode';
}
sub run_v7_tests {
ok (($schema->resultset('RouteChange')->find(1)->can('quuxs_id')),
'correct column accessor in current mode');
+
+ is $schema->resultset('RouteChange')->find(1)->foo2_bar, 3,
+ 'correct column accessor for column with word ending with digit in current mode';
}
{
)|,
q|CREATE TABLE RouteChange (
id INTEGER PRIMARY KEY,
- QuuxsId INTEGER REFERENCES quuxs (quuxid)
+ QuuxsId INTEGER REFERENCES quuxs (quuxid),
+ Foo2Bar INTEGER
)|,
q|CREATE TABLE email (
id INTEGER PRIMARY KEY,
q|INSERT INTO quuxs VALUES (1,20)|,
q|INSERT INTO quuxs VALUES (2,19)|,
q|INSERT INTO stations_visited VALUES (1,1)|,
- q|INSERT INTO RouteChange VALUES (1,1)|,
+ q|INSERT INTO RouteChange VALUES (1,1,3)|,
);
END { unlink($fn); }