Search in sources :

Example 1 with Arguments

use of org.apache.jmeter.config.Arguments in project ACS by ACS-Community.

the class CCSampler method getDefaultParameters.

/**
	 * Provide a list of parameters which this test supports.  Any
	 * parameter names and associated values returned by this method
	 * will appear in the GUI by default so the user doesn't have
	 * to remember the exact names.  The user can add other parameters
	 * which are not listed here.  If this method returns null then
	 * no parameters will be listed.  If the value for some parameter
	 * is null then that parameter will be listed in the GUI with
	 * an empty value.
	 * 
	 * @return  a specification of the parameters used by this
	 *           test which should be listed in the GUI, or null
	 *           if no parameters should be listed.
	 */
public Arguments getDefaultParameters() {
    Arguments params = new Arguments();
    params.addArgument("Manager", DEFAULT_MANAGER);
    params.addArgument("ClientName", CLIENT_NAME);
    params.addArgument("Initialize", String.valueOf(INITIALIZE));
    return params;
}
Also used : Arguments(org.apache.jmeter.config.Arguments)

Example 2 with Arguments

use of org.apache.jmeter.config.Arguments in project ACS by ACS-Community.

the class T23Sampler method getDefaultParameters.

/**
	 * Provide a list of parameters which this test supports.  Any
	 * parameter names and associated values returned by this method
	 * will appear in the GUI by default so the user doesn't have
	 * to remember the exact names.  The user can add other parameters
	 * which are not listed here.  If this method returns null then
	 * no parameters will be listed.  If the value for some parameter
	 * is null then that parameter will be listed in the GUI with
	 * an empty value.
	 * 
	 * @return  a specification of the parameters used by this
	 *           test which should be listed in the GUI, or null
	 *           if no parameters should be listed.
	 */
public Arguments getDefaultParameters() {
    Arguments params = new Arguments();
    params.addArgument("ThreadNum", "${__threadNum}");
    params.addArgument(TEST_PREFIX, TEST);
    params.addArgument("SizeOfSet", String.valueOf(SIZE_OF_SET));
    params.addArgument("Delay", String.valueOf(DELAY));
    return params;
}
Also used : Arguments(org.apache.jmeter.config.Arguments)

Example 3 with Arguments

use of org.apache.jmeter.config.Arguments in project jmeter by apache.

the class UrlConfigGui method noData.

/**
     * Checks if no data is available in the selected tab
     *
     * @param oldSelectedIndex the tab to check for data
     * @return true if neither Parameters tab nor Raw Body tab contain data
     */
boolean noData(int oldSelectedIndex) {
    if (oldSelectedIndex == tabRawBodyIndex) {
        return StringUtils.isEmpty(postBodyContent.getText().trim());
    } else {
        boolean noData = true;
        Arguments element = (Arguments) argsPanel.createTestElement();
        if (showFileUploadPane) {
            noData &= !filesPanel.hasData();
        }
        return noData && StringUtils.isEmpty(computePostBody(element));
    }
}
Also used : Arguments(org.apache.jmeter.config.Arguments)

Example 4 with Arguments

use of org.apache.jmeter.config.Arguments in project translationstudio8 by heartsome.

the class LicenseActivateCheckDeactivate method getDefaultParameters.

public Arguments getDefaultParameters() {
    Arguments args = new Arguments();
    args.addArgument("LicenseID", "89U1jiKrhD5IG1yNU0O2CinG");
    args.addArgument("HardwareCode", "TestHW");
    args.addArgument("InstallCode", "TestInstall");
    args.addArgument("WaitSeconds", "5");
    args.addArgument("IntervalSeconds", "30");
    return args;
}
Also used : Arguments(org.apache.jmeter.config.Arguments)

Example 5 with Arguments

use of org.apache.jmeter.config.Arguments in project jmeter-plugins by undera.

the class ParameterizedController method processVariables.

private void processVariables() {
    final Arguments args1 = (Arguments) this.getUserDefinedVariablesAsProperty().getObjectValue();
    Arguments args = (Arguments) args1.clone();
    final JMeterVariables vars = JMeterContextService.getContext().getVariables();
    Iterator<Entry<String, String>> it = args.getArgumentsAsMap().entrySet().iterator();
    Entry<String, String> var;
    while (it.hasNext()) {
        var = it.next();
        log.debug("Setting " + var.getKey() + "=" + var.getValue());
        vars.put(var.getKey(), var.getValue());
    }
}
Also used : JMeterVariables(org.apache.jmeter.threads.JMeterVariables) Entry(java.util.Map.Entry) Arguments(org.apache.jmeter.config.Arguments)

Aggregations

Arguments (org.apache.jmeter.config.Arguments)97 Test (org.junit.jupiter.api.Test)32 HTTPSamplerBase (org.apache.jmeter.protocol.http.sampler.HTTPSamplerBase)18 SampleResult (org.apache.jmeter.samplers.SampleResult)17 Argument (org.apache.jmeter.config.Argument)15 HTTPArgument (org.apache.jmeter.protocol.http.util.HTTPArgument)10 JMeterProperty (org.apache.jmeter.testelement.property.JMeterProperty)8 HTTPFileArg (org.apache.jmeter.protocol.http.util.HTTPFileArg)7 ParameterizedTest (org.junit.jupiter.params.ParameterizedTest)7 ConfigTestElement (org.apache.jmeter.config.ConfigTestElement)6 TestElement (org.apache.jmeter.testelement.TestElement)6 TestElementProperty (org.apache.jmeter.testelement.property.TestElementProperty)5 Test (org.junit.Test)5 HTTPFileArgs (org.apache.jmeter.protocol.http.util.HTTPFileArgs)4 JMeterVariables (org.apache.jmeter.threads.JMeterVariables)4 IOException (java.io.IOException)3 URL (java.net.URL)3 Iterator (java.util.Iterator)3 JMeterTreeNode (org.apache.jmeter.gui.tree.JMeterTreeNode)3 CollectionProperty (org.apache.jmeter.testelement.property.CollectionProperty)3