or die $tr->error;
my $out = $t->translate( catfile($Bin, qw/data diff/, $_ ) )
or die $tr->error;
-
+
my $schema = $t->schema;
unless ( $schema->name ) {
$schema->name( $_ );
} (qw/create1.yml create2.yml/);
# Test for differences
-my $out = SQL::Translator::Diff::schema_diff( $source_schema, 'SQLite', $target_schema, 'SQLite',
- { no_batch_alters => 1,
+my $out = SQL::Translator::Diff::schema_diff( $source_schema, 'SQLite', $target_schema, 'SQLite',
+ { no_batch_alters => 1,
ignore_missing_methods => 1,
output_db => 'SQLite',
- }
+ }
);
eq_or_diff($out, <<'## END OF DIFF', "Diff as expected");
'position' varchar(50) NOT NULL,
'employee_id' int(11) NOT NULL,
PRIMARY KEY ('position', 'employee_id'),
- FOREIGN KEY('employee_id') REFERENCES 'person'('person_id')
+ FOREIGN KEY ('employee_id') REFERENCES 'person'('person_id')
);
INSERT INTO 'employee_temp_alter' SELECT 'position', 'employee_id' FROM 'employee';
'position' varchar(50) NOT NULL,
'employee_id' int(11) NOT NULL,
PRIMARY KEY ('position', 'employee_id'),
- FOREIGN KEY('employee_id') REFERENCES 'person'('person_id')
+ FOREIGN KEY ('employee_id') REFERENCES 'person'('person_id')
);
INSERT INTO 'employee' SELECT 'position', 'employee_id' FROM 'employee_temp_alter';