Search in sources :

Example 1 with PerfMonCollector

use of kg.apc.jmeter.perfmon.PerfMonCollector in project jmeter-plugins by undera.

the class PerfMonGui method createTestElement.

@Override
public TestElement createTestElement() {
    TestElement te = new PerfMonCollector();
    modifyTestElement(te);
    te.setComment(JMeterPluginsUtils.getWikiLinkText(getWikiPage()));
    return te;
}
Also used : PerfMonCollector(kg.apc.jmeter.perfmon.PerfMonCollector) TestElement(org.apache.jmeter.testelement.TestElement)

Example 2 with PerfMonCollector

use of kg.apc.jmeter.perfmon.PerfMonCollector in project jmeter-plugins by undera.

the class PerfMonGui method modifyTestElement.

@Override
public void modifyTestElement(TestElement te) {
    super.modifyTestElement(te);
    if (grid.isEditing()) {
        grid.getCellEditor().stopCellEditing();
    }
    if (te instanceof PerfMonCollector) {
        PerfMonCollector pmte = (PerfMonCollector) te;
        CollectionProperty rows = JMeterPluginsUtils.tableModelRowsToCollectionProperty(tableModel, PerfMonCollector.DATA_PROPERTY);
        pmte.setData(rows);
    }
    super.configureTestElement(te);
}
Also used : PerfMonCollector(kg.apc.jmeter.perfmon.PerfMonCollector) CollectionProperty(org.apache.jmeter.testelement.property.CollectionProperty)

Example 3 with PerfMonCollector

use of kg.apc.jmeter.perfmon.PerfMonCollector in project jmeter-plugins by undera.

the class PerfMonGui method configure.

@Override
public void configure(TestElement te) {
    super.configure(te);
    PerfMonCollector pmte = (PerfMonCollector) te;
    JMeterProperty perfmonValues = pmte.getMetricSettings();
    if (!(perfmonValues instanceof NullProperty)) {
        JMeterPluginsUtils.collectionPropertyToTableModelRows((CollectionProperty) perfmonValues, tableModel);
    } else {
        log.warn("Received null property instead of collection");
    }
}
Also used : PerfMonCollector(kg.apc.jmeter.perfmon.PerfMonCollector) JMeterProperty(org.apache.jmeter.testelement.property.JMeterProperty) NullProperty(org.apache.jmeter.testelement.property.NullProperty)

Example 4 with PerfMonCollector

use of kg.apc.jmeter.perfmon.PerfMonCollector in project jmeter-plugins by undera.

the class PerfMonGuiTest method testModifyTestElement.

@Test
public void testModifyTestElement() {
    System.out.println("modifyTestElement");
    TestElement c = new PerfMonCollector();
    PerfMonGui instance = new PerfMonGui();
    instance.modifyTestElement(c);
}
Also used : PerfMonCollector(kg.apc.jmeter.perfmon.PerfMonCollector) TestElement(org.apache.jmeter.testelement.TestElement) Test(org.junit.Test)

Example 5 with PerfMonCollector

use of kg.apc.jmeter.perfmon.PerfMonCollector in project jmeter-plugins by undera.

the class PerfMonGuiTest method testConfigure.

@Test
public void testConfigure() {
    System.out.println("configure");
    TestElement el = new PerfMonCollector();
    PerfMonGui instance = new PerfMonGui();
    instance.configure(el);
}
Also used : PerfMonCollector(kg.apc.jmeter.perfmon.PerfMonCollector) TestElement(org.apache.jmeter.testelement.TestElement) Test(org.junit.Test)

Aggregations

PerfMonCollector (kg.apc.jmeter.perfmon.PerfMonCollector)7 TestElement (org.apache.jmeter.testelement.TestElement)4 Test (org.junit.Test)4 CollectionProperty (org.apache.jmeter.testelement.property.CollectionProperty)1 JMeterProperty (org.apache.jmeter.testelement.property.JMeterProperty)1 NullProperty (org.apache.jmeter.testelement.property.NullProperty)1