Closed skelzer closed 1 year ago
I think we can extend the test-nginx framework.
add a new session which will sort the json before compare the body --- response_body_json:
Awesome, that worked great :)
This was a life saver. Could we add this to this guide: https://openresty.gitbooks.io/programming-openresty/content/testing/test-file-layout.html
@frankgreco would you please create a PR for your proposal?
@zhuizhuhaomeng It seems the version installed when doing cpan install Test::Nginx
is 0.30
which does not contain this fix. I had to build from source for it to work. Would you be able to publish a new version of this module?
Hello!,
First of all, sorry if this is a dumb question, but I have never used nginx or Perl before, so I'm a bit at a loss.
I am trying to validate an endpoint that should serve a JSON as a response. Since JSONs are by definition unsorted, how should I go about validating this response? Is this even possible in this framework?
Thanks :)