Hi,
I am facing an issue when I am running Sequential scenarios.
e.g. I have three scenarios scn1, scn2, scn2. I want to execute scn1, and scn2 first and then scn3 at the end.
I have ArraySeq of PopulationBuilder which works perfectly fine when I am running standalone tests without using the andThen feature.
def scn(scnName: String, scnBuild: ScenarioBuilder, scnUser: Int): ScenarioBuilder = scenario(scnName + " VUsers: " + scnUser).repeat(NoOfIteration, "iterationNumber") {
exec(scnBuild)
}
val stepsI: mutable.ArraySeq[PopulationBuilder] = new Array[PopulationBuilder](scnNameArr.length)
for (i <- scnNameArr.indices) {
val scnUser: Int = Random.nextInt(10)
stepsI(i) = scn(scnNameArr(i), scnNameArr(i), scnUser).inject(
rampUsers(scnUser) during (scnUser seconds)
)
}
stepsI
When I am running the below setUp it’s working fine:
setUp(stepsI.toSeq: _*).protocols(myProtocol)
But when I am trying to use andThen feature it’s not getting recognized, below is the setup that I am trying to achieve:
setUp(
stepsI.toSeq: _*
.andThen(/*here is my child scenario injection*/)
).protocols(myProtocol)
when I mouse hover to andThen it says Cannot resolve overloaded method ‘andThen’
Please help!
Thanks & regards,
Raman