Introduction
Using ATS you will be reviewing your test results mainly on the web UI of Test Explorer. The first page you will see is the one which lists all your RUNS
Here is how the RUNS page may look like:
As you can see the name of the RUN will inform you what these tests are actually covering. The next columns will give you some info about the tested application.
This page shows how you can set the important information about your RUN.
Changing the RUN information
Using the ats.config.properties file
Place the following entries in a file called ats.config.properties which is placed in the root of your classpath. For Maven the defaults are either src/main/resources or src/test/resources.
# the name of the Run ats.db.logging.run.name=Performance tests of my Product # the operating system ats.db.logging.run.os=Linux RHEL 7 # the name of the tested application ats.db.logging.run.product=My Cool Product # the product version ats.db.logging.run.version=2.3.17 # the product build number ats.db.logging.run.build=2000
ATS will read this file on startup and will use this information to set the RUN info
Using Java code
Have a look at the following code:
import com.axway.ats.log.AtsDbLogger; AtsDbLogger atsDbLogger = AtsDbLogger.getLogger( BaseTest.class.getName() ); atsDbLogger.updateRun( "Another Run name", "Another OS", "Another Product name", "Another Product Version number", "Another Product Build number", "Some user note about this run" );
Here we create an instance of the AtsDbLogger class which is used by ATS for managing the logging and we use its updateRun method.
The values we have used in this example tell you what kind of information can be changed - the parameters are the same when using a properties file with the addition of the last one which is to add some user message containing information about the current run.
In case you do not want to modify all the Run info, you just need to pass null values for the parameters that should not be touched. The next example modifies the user note only:
atsDbLogger.updateRun( null, null, null, null, null, "Some user note about this run" );
Which option to use?
The first option(using the config.properties file) is good to provide all the information you know prior to starting your tests.
The second option(using Java code) is good to provide information you do not know prior to starting your tests,
Of course, you can use either one of them or both.
Back to parent page
Go to Table of Contents