Tweaked to use the default reading of __DATA__
Mark Addison [Fri, 14 May 2004 03:36:32 +0000 (03:36 +0000)]
t/34tt-base.t
t/lib/Producer/BaseTest.pm

index 3841268..fc67484 100644 (file)
@@ -38,9 +38,6 @@ $obj = SQL::Translator->new(
     from           => "XML-SQLFairy",
     filename       => "$Bin/data/xml/schema-basic.xml",
     to             => "Producer::BaseTest::produce",
-    producer_args  => {
-        ttfile => "$Bin/data/template/basic.tt",
-    },
 );
 my $out;
 lives_ok { $out = $obj->translate; }  "Translate ran";
index a0e76c2..a31c682 100644 (file)
@@ -9,7 +9,8 @@ use base qw/SQL::Translator::Producer::TT::Base/;
 # Make sure we use our new class as the producer
 sub produce { return __PACKAGE__->new( translator => shift )->run; };
 
-sub tt_schema { local $/ = undef; \<DATA>; }
+# Note: we don't need to impliment tt_schema as the default will use the DATA
+# section by default.
 
 sub tt_vars { ( foo => "bar" ); }