sub run_tests {
my $self = shift;
- plan tests => 99;
+ plan tests => 101;
$self->create();
is( $obj2->id, 2 );
SKIP: {
- skip $self->{skip_rels}, 61 if $self->{skip_rels};
+ skip $self->{skip_rels}, 63 if $self->{skip_rels};
my $moniker3 = $monikers->{loader_test3};
my $class3 = $classes->{loader_test3};
ok ((not exists $rsobj3->result_source->relationship_info('loader_test4zes')->{attrs}{on_update}),
'has_many does not have on_update');
+ ok ((not exists $rsobj3->result_source->relationship_info('loader_test4zes')->{attrs}{is_deferrable}),
+ 'has_many does not have is_deferrable');
+
isnt $rsobj4->result_source->relationship_info('fkid_singular')->{attrs}{on_delete}, 'CASCADE',
"on_delete => 'CASCADE' not on belongs_to by default";
isnt $rsobj4->result_source->relationship_info('fkid_singular')->{attrs}{on_update}, 'CASCADE',
"on_update => 'CASCADE' not on belongs_to by default";
+ isnt $rsobj4->result_source->relationship_info('fkid_singular')->{attrs}{is_deferrable}, 1,
+ "is_deferrable => 1 not on belongs_to by default";
+
ok ((not exists $rsobj4->result_source->relationship_info('fkid_singular')->{attrs}{cascade_delete}),
'belongs_to does not have cascade_delete');
$dbh->disconnect;
}
- my @new = $conn->rescan;
+ my @new = do {
+ local $SIG{__WARN__} = sub {};
+ $conn->rescan;
+ };
is(scalar(@new), 1);
is($new[0], 'LoaderTest30');
dat VARCHAR(8),
from_id INTEGER,
to_id INTEGER,
- PRIMARY KEY (id1,id2)
+ PRIMARY KEY (id1,id2),
FOREIGN KEY (from_id) REFERENCES loader_test4 (id),
FOREIGN KEY (to_id) REFERENCES loader_test4 (id)
) $self->{innodb}