X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FSQL%2FAbstract%2FTest.pm;h=e163f2c5987a0758e96bce06276e752b45f96d83;hb=8480fb63ab259ac41af9d6570eb313cb23c5eac8;hp=c642f4289b9aba2ee85ce0087b6b5bdb5658da29;hpb=67e082b8fc8fad7ebeaf57b75eca4f5ef3d46360;p=scpubgit%2FQ-Branch.git diff --git a/lib/SQL/Abstract/Test.pm b/lib/SQL/Abstract/Test.pm index c642f42..e163f2c 100644 --- a/lib/SQL/Abstract/Test.pm +++ b/lib/SQL/Abstract/Test.pm @@ -22,11 +22,20 @@ use SQL::Abstract::Tree; my $wrapped = sub { my ($self, @args) = @_; my $e1 = $self->$orig(@args); + return $e1 if our $Stab_Check_Rec; + local $Stab_Check_Rec = 1; my $e2 = $self->$orig($e1); + my ($d1, $d2) = map Data::Dumper::Concise::Dumper($_), $e1, $e2; (our $tb)->is_eq( - (map Data::Dumper::Concise::Dumper($_), $e2, $e1), + $d2, $d1, 'expand_expr stability ok' - );# or die; + ) or do { + require Path::Tiny; + Path::Tiny->new('e1')->spew($d1); + Path::Tiny->new('e2')->spew($d2); + system('diff -u e1 e2 1>&2'); + die "Differences between e1 and e2, bailing out"; + }; return $e1; }; no strict 'refs'; no warnings 'redefine';