Skip to content

Instantly share code, notes, and snippets.

@emersonf
Last active December 13, 2015 23:09
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save emersonf/4989430 to your computer and use it in GitHub Desktop.
session access in Gatling
import com.excilys.ebi.gatling.core.Predef._
class Foo(val a:Int, val b:Int)
class TestSimulation extends Simulation {
val scn = scenario("testScenario")
.exec(session => session.setAttribute("foo", new Foo(1, 2)))
.exec(session => {
println(session.getAttribute("foo.a"))
session
})
setUp(scn.users(1))
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment