abao icon indicating copy to clipboard operation
abao copied to clipboard

Testing requests with required queryParameters

Open honzatrtik opened this issue 9 years ago • 13 comments

Hello, is there a way, how to test request with required query params? I would add query param in a hook, but there is no such parsed info in test.request...

Thanks for the suggestions!

honzatrtik avatar Mar 07 '15 20:03 honzatrtik

please use test.request.query, it's mentioned in hooks part of README

cybertk avatar Mar 09 '15 00:03 cybertk

I was hoping there is a way to modify requests globally in beforeAll and use some parsed data from queryParams raml definition. Anyway, i can set up individual hooks for appropriate endpoint tests. Thank you for your answer!

honzatrtik avatar Mar 09 '15 14:03 honzatrtik

What is your case?

Is it OK if abao can parse/use queryParams in raml for each individual API?

cybertk avatar Mar 10 '15 00:03 cybertk

I have lot of API endpoints with required queryParams, so if abao parses / sends required queryParams in test requests (similar to uriParameters), it would be nice!

honzatrtik avatar Mar 10 '15 09:03 honzatrtik

Add to plan

cybertk avatar May 28 '15 18:05 cybertk

Have you finished this feature?

davidli2017 avatar Jan 06 '16 12:01 davidli2017

@honzatrtik How do you resolve this problem ? I have the same problem,can you give some advise

davidli2017 avatar Jan 06 '16 12:01 davidli2017

i have fixed this feature , can i create a feature branch?

davidli2017 avatar Jan 07 '16 08:01 davidli2017

@cybertk Hello. Could you help merge this pull request? I also wrote some unit tests for it. Our project really need this feature. Currently we are downloading dependencies directly from Github. But we hope this feature can be released to npm.

liweinan0423 avatar Jul 14 '16 07:07 liweinan0423

This issue should be closed now. @Cybertk, Could you also release a new version to NPM?

liweinan0423 avatar Jul 19 '16 06:07 liweinan0423

@plroebuck @galk-in I think we can release v0.4 now. Could you please help prepare the release note, or we can just extract them from all the previous beta tags?

cybertk avatar Jul 19 '16 07:07 cybertk

@cybertk I think we can just extract.

galkin avatar Jul 19 '16 07:07 galkin

Cool, I will do this.

cybertk avatar Jul 19 '16 08:07 cybertk