1 package test.methodselectors; 2 3 import org.testng.annotations.Test; 4 5 import test.BaseTest; 6 7 public class BeanShellTest extends BaseTest { 8 9 @Test onlyGroup1()10 public void onlyGroup1() { 11 addClass("test.methodselectors.SampleTest"); 12 setBeanShellExpression("groups.\n containsKey \t (\"test1\")"); 13 run(); 14 String[] passed = { 15 "test1", 16 }; 17 String[] failed = { 18 }; 19 verifyTests("Passed", passed, getPassedTests()); 20 verifyTests("Failed", failed, getFailedTests()); 21 } 22 ppp(String s)23 public static void ppp(String s) { 24 System.out.println("[MethodSelectorTest] " + s); 25 } 26 } 27