1 package test.thread;
2 
3 import org.testng.ITestContext;
4 import org.testng.annotations.BeforeMethod;
5 import org.testng.annotations.Test;
6 
7 public class Sample2 extends BaseThreadTest {
8 
9   @BeforeMethod
before(ITestContext ctx)10   public void before(ITestContext ctx) {
11     logSuite(ctx.getSuite().getName(), System.currentTimeMillis());
12   }
13 
14   @Test
s1()15   public void s1() {
16     logThread(Thread.currentThread().getId());
17   }
18 }
19