Permalink
Browse files

if parse fails in test then report the text being parsed

  • Loading branch information...
1 parent c97265b commit 8acd093f387297cdd147c8b2ba828daeeda472b1 @timbunce committed Aug 29, 2010
Showing with 4 additions and 2 deletions.
  1. +2 −1 t/03_class.t
  2. +2 −1 t/55_final.t
View
3 t/03_class.t
@@ -24,7 +24,8 @@ plan tests => 3;
my $parser = Java::Javap::Grammar->new();
my $decomp = Java::Javap->javap('ClassTest', {-classpath=>'testjavas'});
-my $tree = $parser->comp_unit( $decomp );
+my $tree = $parser->comp_unit( $decomp )
+ or die "Error parsing:\n$decomp";
my $expected_tree = {
'parent' => 'java.lang.Object',
View
3 t/55_final.t
@@ -22,7 +22,8 @@ plan tests => 1;
my $parser = Java::Javap::Grammar->new();
my $decomp = Java::Javap->javap('FinalClassTest', {-classpath => 'testjavas'});
-my $tree = $parser->comp_unit( $decomp );
+my $tree = $parser->comp_unit( $decomp )
+ or die "Error parsing:\n$decomp";
my $expected_tree = {
'parent' => 'java.lang.Object',

0 comments on commit 8acd093

Please sign in to comment.