Skip Menu |
 

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Test-Deep-JSON CPAN distribution.

Report information
The Basics
Id: 93273
Status: resolved
Priority: 0/
Queue: Test-Deep-JSON

People
Owner: Nobody in particular
Requestors: ether [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 0.02
Fixed in: 0.03



Subject: Nested test functions do not work
Download (untitled) / with headers
text/plain 526b
This test: cmp_deeply( $json_string, json(code( sub { return 0 } )), ); does not work, with the error: Use of uninitialized value $diag in substitution (s///) at /Users/ether/.perlbrew/libs/19.8@std/lib/perl5/Test/Deep.pm line 225. This is because diagnostics() is being called, but the inner object is not being called to get the error message. The fix is the same I did here, for Test::Deep::YAML: https://github.com/karenetheridge/Test-Deep-YAML/commit/9c7e0b3a898b9a66fd1bed55c677b2e1610e7c63
Download (untitled) / with headers
text/plain 636b
Thank you, would be fixed in version 0.03. On 2014-02-22T20:19:28-05:00, ETHER wrote: Show quoted text
> This test: > > cmp_deeply( > $json_string, > json(code( sub { return 0 } )), > ); > > does not work, with the error: > > Use of uninitialized value $diag in substitution (s///) at > /Users/ether/.perlbrew/libs/19.8@std/lib/perl5/Test/Deep.pm line 225. > > This is because diagnostics() is being called, but the inner object is > not being called to get the error message. > > The fix is the same I did here, for Test::Deep::YAML: > https://github.com/karenetheridge/Test-Deep- > YAML/commit/9c7e0b3a898b9a66fd1bed55c677b2e1610e7c63


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.