-
-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow different verbs payload #8
Conversation
…get and post calls to k6, use payload in post calls
Thanks! Currently at Laracon AU, but I will check this after. |
…he payload must be provided with the post argument / method
@nahime0 Are you able to PR the other verbs? Like put, delete, etc? |
Hi @nunomaduro, Yes, of course. I'll be engaged on a test for a job position till tomorrow noon. I'll be back on this right after. |
@nunomaduro Just opened a new PR #15 |
@nunomaduro do you think is pertinent to have a option where we can stress test with a dynamic payload? Let's say we are stress testing a payment gateway, and we want to hit the STORE payment multiple times with multiple ids. Maybe we can stress with different payload/id for each request |
This PR introduces support to POST requests.
Two new options has been introduces:
The two options will be forwarded to k6 using the already defined options environment variable.
The run.js used by k6 has been adapted to use get or post based on the method, and to use the payload variable only if the required method is post.
@nunomaduro I haven't written any test. I don't know if you want to use a different test suite, as the default one uses the same stress object for all requests (defined in the beforeEach of Pest.php).