Class JMeterArgumentsArray


  • public class JMeterArgumentsArray
    extends Object
    Creates an arguments array to pass to the JMeter object to run tests.
    Author:
    Mark Collin
    • Constructor Detail

      • JMeterArgumentsArray

        public JMeterArgumentsArray​(boolean disableGUI,
                                    String jMeterHomeDirectory)
                             throws org.apache.maven.plugin.MojoExecutionException
        Create an instance of JMeterArgumentsArray
        Parameters:
        disableGUI - If GUI should be disabled or not
        jMeterHomeDirectory - The JMETER_HOME directory, what JMeter bases its classpath on
        Throws:
        org.apache.maven.plugin.MojoExecutionException - Exception
    • Method Detail

      • addExtraArgument

        public JMeterArgumentsArray addExtraArgument​(String argument)
        Add a custom argument to the list of JMeter arguments that will override the arguments in the property files.
        Parameters:
        argument - an argument like -Jtest.port=8080
      • setResultFileOutputFormatIsCSV

        public JMeterArgumentsArray setResultFileOutputFormatIsCSV​(boolean isCSVFormat)
      • getResultsLogFileName

        public String getResultsLogFileName()
      • buildArgumentsArray

        public List<String> buildArgumentsArray()
                                         throws org.apache.maven.plugin.MojoExecutionException
        Generate an arguments array representing the command line options you want to send to JMeter. The order of the array is determined by the order the values in JMeterCommandLineArguments are defined.
        Returns:
        An array representing the command line sent to JMeter
        Throws:
        org.apache.maven.plugin.MojoExecutionException - Exception