Running a test scenario

There are a few different ways of running a Gatling performance test on your machine. One of them is through one of the available through Gradle plugins, which provide support for running tests during the building of a project. You may also use Maven plugins or just try to run it from your IDE. If you build your project with Gradle, you can also define simple tasks that just run tests by launching the io.gatling.app.Gatling main class. Here's a definition of such a task in the gradle.build file:

task loadTest(type: JavaExec) {    dependsOn testClasses    description = "Load Test With Gatling"    group = "Load Test"    classpath = sourceSets.test.runtimeClasspath    jvmArgs = [ "-Dgatling.core.directory.binaries=${sourceSets.test.output.classesDir.toString()}" ...

Get Mastering Spring Cloud now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.