]> git.decadent.org.uk Git - maypole.git/blobdiff - t/01basics.t
fixed tests, fixed syntax error in Apache::MVC
[maypole.git] / t / 01basics.t
index 6fa0c1e1241f1b410004e797600bac45456cb800..324bb0bceaa0ad2eedb89e67f7bb5109905b6747 100644 (file)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl -w
 use Test::More;
+use Data::Dumper;
 use lib 'examples'; # Where BeerDB should live
 BEGIN {
     $ENV{BEERDB_DEBUG} = 0;
@@ -32,7 +33,12 @@ like(BeerDB->call_url("http://localhost/beerdb"), qr/frontpage/,
      "Got frontpage, trailing '/' on uri_base but not request");
 
 like(BeerDB->call_url("http://localhost/beerdb/beer/list"), qr/Organic Best/, "Found a beer in the list");
-my (%classdata)=split /\n/, BeerDB->call_url("http://localhost/beerdb/beer/classdata");
+
+my $classdata_page = BeerDB->call_url("http://localhost/beerdb/beer/classdata");
+my (%classdata)=split /\n+/, $classdata_page;
+#warn $classdata_page;
+#warn Dumper(%classdata);
+
 is ($classdata{plural},'beers','classdata.plural');
 is ($classdata{moniker},'beer','classdata.moniker');
 like ($classdata{cgi},qr/^HTML::Element/,'classdata.cgi');