use of org.apache.jmeter.testelement.property.NullProperty in project jmeter-plugins by undera.
the class PageDataExtractorOverTimeGui method configure.
@Override
public void configure(TestElement te) {
super.configure(te);
CorrectedResultCollector rc = (CorrectedResultCollector) te;
JMeterProperty regexpValues = rc.getProperty(REGEXPS_PROPERTY);
if (!(regexpValues instanceof NullProperty)) {
JMeterPluginsUtils.collectionPropertyToTableModelRows((CollectionProperty) regexpValues, tableModel, columnClasses);
regExps = (CollectionProperty) regexpValues;
} else {
log.warn("Received null property instead of collection");
}
}
use of org.apache.jmeter.testelement.property.NullProperty in project jmeter-plugins by undera.
the class UltimateThreadGroup method testStarted.
@Override
public void testStarted() {
JMeterProperty data = getData();
if (!(data instanceof NullProperty)) {
scheduleIT = ((CollectionProperty) data).iterator();
}
threadsToSchedule = 0;
}
use of org.apache.jmeter.testelement.property.NullProperty in project jmeter-plugins by undera.
the class UltimateThreadGroupGui method configure.
@Override
public void configure(TestElement tg) {
// log.info("Configure");
super.configure(tg);
UltimateThreadGroup utg = (UltimateThreadGroup) tg;
// log.info("Configure "+utg.getName());
JMeterProperty threadValues = utg.getData();
if (!(threadValues instanceof NullProperty)) {
CollectionProperty columns = (CollectionProperty) threadValues;
tableModel.removeTableModelListener(this);
JMeterPluginsUtils.collectionPropertyToTableModelRows(columns, tableModel);
tableModel.addTableModelListener(this);
updateUI();
} else {
log.warn("Received null property instead of collection");
}
TestElement te = (TestElement) tg.getProperty(AbstractThreadGroup.MAIN_CONTROLLER).getObjectValue();
if (te != null) {
loopPanel.configure(te);
}
buttons.checkDeleteButtonStatus();
}
use of org.apache.jmeter.testelement.property.NullProperty in project jmeter-plugins by undera.
the class UltimateThreadGroupTest method testGetData_broken_del.
@Test
public void testGetData_broken_del() {
CollectionProperty prop = JMeterPluginsUtils.tableModelRowsToCollectionProperty(dataModel, UltimateThreadGroup.EXTERNAL_DATA_PROPERTY);
instance.setProperty(prop);
CollectionProperty prop2 = JMeterPluginsUtils.tableModelRowsToCollectionProperty(dataModel, UltimateThreadGroup.DATA_PROPERTY);
instance.setProperty(prop2);
JMeterProperty result = instance.getData();
assertEquals(prop2, instance.getProperty(UltimateThreadGroup.DATA_PROPERTY));
assertTrue(instance.getProperty(UltimateThreadGroup.EXTERNAL_DATA_PROPERTY) instanceof NullProperty);
assertFalse(result instanceof NullProperty);
assertEquals(prop.getStringValue(), result.getStringValue());
}
use of org.apache.jmeter.testelement.property.NullProperty in project jmeter-plugins by undera.
the class UltimateThreadGroupTest method testGetData.
@Test
public void testGetData() {
System.out.println("getSchedule");
CollectionProperty prop = JMeterPluginsUtils.tableModelRowsToCollectionProperty(dataModel, UltimateThreadGroup.DATA_PROPERTY);
instance.setData(prop);
JMeterProperty result = instance.getData();
assertFalse(result instanceof NullProperty);
assertEquals(prop.getStringValue(), result.getStringValue());
}
Aggregations