artillery icon indicating copy to clipboard operation
artillery copied to clipboard

Scenarios per phase

Open whitebyte opened this issue 5 years ago • 3 comments

Is there any way to define scenarios per phase? Say, I need to perform requests to endpoint X for 20 seconds, then stop and start calling endpoint Y. Can't find anything related in the docs.

whitebyte avatar Nov 19 '19 13:11 whitebyte

There's no way to associate a scenario definition with a specific phase right now, but you may be able to do it with custom logic in a beforeScenario function or by running two separate Artillery tests -- it depends on what you're trying to do exactly.

hassy avatar Nov 20 '19 12:11 hassy

Well, that's unfortunate. It's definitely possible to work around either using beforeScenario or by managin Artillefy from an external script, but either solution is not too clean. This issue should be considered feature request then.

whitebyte avatar Nov 20 '19 13:11 whitebyte

Agree with this strongly! Trying to replicate some user behavior and being able to plug in different scenarios per phase would be killer.

cleve-fauna avatar Jan 19 '24 18:01 cleve-fauna