4 # Before `make install' is performed this script should be runnable with
5 # `make test'. After `make install' it should work as `perl test.pl'
10 use Test::SQL::Translator qw(maybe_plan);
15 maybe_plan(4, 'YAML', 'Test::Differences')
17 use Test::Differences;
20 # The _GLOBAL_ table should be removed and its fields copied onto all other
46 # Should include the the items added from the Global table defined above in the
47 # schema as well as those defined in the filter args below.
125 parser_type: SQL::Translator::Parser::YAML
127 producer_type: SQL::Translator::Producer::YAML
134 # Parse the test XML schema
136 $obj = SQL::Translator->new(
143 # Filter from SQL::Translator::Filter::*
145 # A global field to add given in the args
149 data_type => 'timestamp',
161 ) or die "Failed to create translator object: ".SQL::Translator->error;
164 lives_ok { $out = $obj->translate; } "Translate ran";
165 is $obj->error, '' ,"No errors";
166 ok $out ne "" ,"Produced something!";
167 eq_or_diff $out, $ans_yaml ,"Output looks right";