My code is as below. I seethat andThen is introduced in a later version. But when I use the below version, it doesnt run
setUp(
allScenarios50.inject(atOnceUsers(rampupUsers) )
.andThen(
historicBidScenarios50.inject(atOnceUsers(rampupUsers) )
)
).protocols(httpProtocol)
type mismatch;
found : io.gatling.core.check.CheckBuilder.Final[io.gatling.core.check.jsonpath.JsonPathCheckType,com.fasterxml.jackson.databind.JsonNode]
required: io.gatling.http.check.HttpCheck
.check(jsonPath(“$[0].panelId”).is(“CUR”))
Sorry, it’s impossible to tell without you providing a full sample, eg a sample project on GitHub.
Then, please note that since Gatling 3.7, Gatling also supports Java and Kotlin.
I would recommend against starting a new Gatling project in Scala unless you’re a Scala developer.
Now after adding scala plugin many errors vanished. The only error now is
Symbol ‘type io.gatling.commons.shared.unstable.model.stats.assertion.AssertionPathParts’ is missing from the classpath.
This symbol is required by ‘method io.gatling.core.assertion.AssertionSupport.string2PathParts’.
Make sure that type AssertionPathParts is in your classpath and check for conflicting dependencies with -Ylog-classpath.
A full rebuild may help if ‘AssertionSupport.class’ was compiled against an incompatible version of io.gatling.commons.shared.unstable.model.stats.assertion.
val rampupUsers: Int = if(System.getProperty(“rampupUsers”) != null && System.getProperty(“rampupUsers”) != “”) System.getProperty(“rampupUsers”).toInt else 50
The sample code is val usersFile: String = if(System.getProperty(“users”) != null && System.getProperty(“users”) != “”) System.getProperty(“users”) else "users.csv" val rampupUsers: Int = if(System.getProperty(“rampupUsers”) != null && System.getProperty(“rampupUsers”) != “”) System.getProperty(“rampupUsers”).toInt else 50
setUp(
allScenarios.inject(atOnceUsers(rampupUsers) )
.andThen(
historicScenarios.inject( rampUsers(rampupUsers) during (1 minute) )
)
I hope the sample is clear. I cannot share the whole in github, since beacuse of company regulations.