Junit Annotations
Junit Annotations
--Run from Excel the testcases ===Assume.assumeTrue(False); in the end of the cl ass/function then that function will not executed. TCID,DEscription,Runmode in excel. For Parametrizing Tests Step1: @RunWith(Parametrized.class) --above the class Step2: Public Public Step3: Declare global Variables String bankName; int acctnaum; Build a constructor(Initialises the object)
Public SeconTest(String bankName ,int acctNum){ this.bankName =bankName; this.acctNume =actNum; } Step4: @Parameters Public static Collection<Object[]> getData(){ object data[][] =new object[1][2] // ist row data[0][0] ="HSBC"; data[0][1] ="1234"; return Arrays.asList(data); } no of colums =no of variables