Priceline Negotiator
Priceline Negotiator

Reputation: 410

How to run a Karate Feature file after a Gatling simulation completes

I have two Karate Feature files

  1. One for creating a user (CreateUser.feature)
  2. One for getting a count of users created (GetUserCount.feature)

I have additionally one Gatling Scala file

  1. This calls CreateUser.feature with rampUser(100) over (5 seconds)

This works perfect. What i'd like to know is how can I call GetUserCount.feature after Gatling finishes it's simulation? It must only be called one time to get the final created user count. What are my options and how can I implement them?

Upvotes: 1

Views: 877

Answers (1)

Peter Thomas
Peter Thomas

Reputation: 58058

Best option is use the Java API to run a single feature in the Gatling simulation.

Runner.runFeature("classpath:mock/feeder.feature", null, false)

Upvotes: 2

Related Questions