[#1875] John/Kavitha - Added test for malformed json handling and improv...

...ed error message.