Sunday, October 14, 2012

Tip #16: How to save test results - part 2

In the previous part I wrote how to save the testing results using Simple Data Writer. There is one more way about how to do it - using the command line options.

So, if you want to run the test plan from file test.jmx and save the testing results to the file log.jtl, use the following command:
jmeter -n -t test.jmx -l log.jtl
You can configure how the result data will be saved by editing the file jmeter.properties (section "Results file configuration"). For example, if you want to save the results in CSV format you should edit the following property:
jmeter.save.saveservice.output_format=csv
This way is more powerful than the one described in the previous part (Simple Data Writer) because it allows you to set some additional options like CSV delimiter, timestamp format, etc. Sometimes it could be very helpful.

2 comments:

  1. Can u plz tell me how to save data of listener in csv automatically.

    ReplyDelete
  2. From what I understand, you can either use a Listener using the JMeter GUI or use the command as described above. If you do use the Listener, there is an option to define an output file. Just type in the name of a csv file and the results will be written to it every time.

    ReplyDelete