assertEquals("times", vars.getObject("OUTVAR_g2"));
}
public void testVariableExtractionFromVariable7() throws Exception {
params = new LinkedList<CompoundVariable>();
params.add(new CompoundVariable("(\\d+)\\s+(\\w+)"));
params.add(new CompoundVariable("pre$1$mid$2$post")); // template
params.add(new CompoundVariable("1")); // match number
params.add(new CompoundVariable("-")); // ALL separator
params.add(new CompoundVariable("default"));
params.add(new CompoundVariable("OUTVAR"));
params.add(new CompoundVariable(INPUT_VARIABLE_NAME));
variable.setParameters(params);
String match = variable.execute(result, null);
assertEquals("1", vars.getObject("OUTVAR_matchNr"));
assertEquals("pre123midtimespost", match);
assertEquals("pre123midtimespost", vars.getObject("OUTVAR"));