Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using Gatling as an integration test tool

Currently I have a small suite of integration tests running against my web-server which makes a request and asserts some assumptions on what the responses should be. These are written in Ruby generating http requests.

I've been looking at Gatling as a stress testing tool but I'm wondering if it could also be used for an integration tests as well. This way all the endpoint requests could be reused across the the stress tests and the integration tests.

I'm probably losing something here from not having the BDD of RSpec but gaining not having to create the same tests twice.

Does anyone have any experience of using gatling in this way?

like image 241
Neil Avatar asked Mar 21 '14 15:03

Neil


People also ask

Can Gatling be used for API testing?

This is why load testing APIs is one of the most common use cases for Gatling users. How does it work with Gatling? Gatling's simulations are code. You can bootstrap your simulation with Gatling's recorder.

Which tool can be used integration testing?

Developers who use the C or C++ programming languages to create embedded software use the VectorCAST/C++ tool. It is used to automate unit and integration testing and to expedite the test workflow.

Is Gatling good for performance testing?

JMeter and Gatling are one of the most popular performance testing tools.


1 Answers

You can use the Assertion API and set up acceptance criteria.

However, Gatling isn't a browser and won't run/test your Javascript, so this approach is only realistic when dealing with server side content, such as testing REST APIs. Here's an example.

like image 160
Stephane Landelle Avatar answered Oct 17 '22 16:10

Stephane Landelle