Advertisement
Guest User

Untitled

a guest
May 3rd, 2016
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. def testScenario(duration: Int) = scenario("SO").during(duration) {
  2. exec {
  3. session => {
  4. val test = StructuredDataCollection.next()
  5. val title = test.title
  6. val method = test.method // Not being used, because it does not work like that :(
  7. val endpoint = test.endpoint
  8. val requiredParameters = test.requiredParameters
  9. val code = test.code
  10. session
  11. .set("title", title)
  12. .set("methodFUG", method).set("endpoint", endpoint)
  13. .set("requiredParameters", requiredParameters)
  14. .set("code", code)
  15. }
  16. }
  17. .exec(
  18. http("${title}")
  19. .httpRequest("get", "${endpoint}") // TODO: method can't be passed in as an expression. FU Gatling!
  20. .queryParamMap("${requiredParameters}")
  21. .check(status.is("${code}"))
  22. )
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement