Skip to content

Instantly share code, notes, and snippets.

@swapnil-kotwal-sp
Created March 8, 2017 14:54
Show Gist options
  • Save swapnil-kotwal-sp/c2dbcabaee7b12c138e9f7f2eceef13a to your computer and use it in GitHub Desktop.
Save swapnil-kotwal-sp/c2dbcabaee7b12c138e9f7f2eceef13a to your computer and use it in GitHub Desktop.
Gatling Session API
var fileBFeeder = csv("fileB.csv").circular
val scn = scenario("test")
.feed(fileBFeeder)
.exec(http("My Req")
.get("/api/users")
.check(
regex("""${account_id}""")
.saveAs("account_id")))
.exec(session => {
// print account name.
println(" Login Account >>> " + session("account_id").as[String])
session})
.pause(1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment