Skip Menu |

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

Report information
The Basics
Id: 100490
Status: new
Priority: 0/
Queue: Test-Rest

People
Owner: Nobody in particular
Requestors: matrix.ppc [...] gmail.com
Cc:
AdminCc:

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



Subject: Test::Rest improvement
Date: Fri, 21 Nov 2014 11:28:00 +0100
To: bug-Test-Rest [...] rt.cpan.org
From: "matrix.ppc" <matrix.ppc [...] gmail.com>
Hello, I use your module, but I have issues due to I need to send/receive JSON data from the server. I attach the changes that I've made to the Test/Rest/Commands.pm and Test/Rest/Context.pm in order to support it. If possible, add to your module. Thanks and keep to good work! ----- diff Commands.pm.stock Commands.pm.modified 150c149,152 < if (_has_child_elements($child)) { --- Show quoted text
> if (($child->localname eq 'Content') &&
(lc($child->getAttribute('leave')) eq 'true')) { Show quoted text
> $hash->{$child->localname} = $child->textContent; > } > elsif (_has_child_elements($child)) {
----- diff Context.pm.stock Context.pm.modified 34a35,38 Show quoted text
> elsif ($response->header('Content-Type') =~ /\bjson\b/) { > use JSON::XS; > $document = JSON::XS::decode_json($response->decoded_content); > }
Robert