Skip to content

biski/gatling2allure

Repository files navigation

Gatling2Allure converter

Tired of analyzing Gatling text logs to extract useful information? Convert Gatling log to beautiful Allure report. See example Allure report

Configuration

logback.xml in Gatling project

Ensure that Gatling logs passed and failed requests with responses to file. Change logback.xml configuration:

<timestamp key="date" datePattern="yyyyMMddHHmmss" />

<appender name="FILE" class="ch.qos.logback.core.FileAppender">
	<file>target/simulation-${date}.log</file>
	<encoder>
		<pattern>%d{HH:mm:ss.SSS} [%-5level] %logger{15} - %msg%n%rEx</pattern>
	</encoder>
</appender>
<!-- Uncomment for logging ALL HTTP request and responses -->
<logger name="io.gatling.http.ahc" level="TRACE" />
<logger name="io.gatling.http.response" level="TRACE" />
<root level="WARN">
    <appender-ref ref="CONSOLE" />
    <appender-ref ref="FILE" />
</root>

Run

Run from IDE

@TODO

Run from jar

  • run Gatling tests
  • run gatling2allure converter:
java -jar <jar_name> /path/to/simulation.log
  • generate Allure report
  • open report in Firefox