t4.set(0,"this is a match");
t4.set(1, "this is a (.+?)");
t4.set(2, 1);
REGEX_EXTRACT func = new REGEX_EXTRACT();
String r = func.exec(t1);
assertTrue(r.equals("term1"));
r = func.exec(t2);
assertTrue(r==null);
r = func.exec(t3);
assertTrue(r==null);