diff --git a/uitest-resident/src/main/java/io/mosip/testrig/residentui/testcase/LoginTest.java b/uitest-resident/src/main/java/io/mosip/testrig/residentui/testcase/LoginTest.java index 86e06ce1..54cdcd9c 100644 --- a/uitest-resident/src/main/java/io/mosip/testrig/residentui/testcase/LoginTest.java +++ b/uitest-resident/src/main/java/io/mosip/testrig/residentui/testcase/LoginTest.java @@ -13,10 +13,11 @@ @Test(groups = "LG") public class LoginTest extends BaseClass { - + public static int run=0; @Test(priority = 0) public static void loginTest() throws Exception { + String envPath = ConfigManager.getiam_residentportal_path(); String otp = ""; String externalemail = ConfigManager.getexternalemail(); driver.get(envPath); @@ -36,13 +37,14 @@ public static void loginTest() throws Exception { } Commons.click( driver, By.id("verify_otp")); Commons.wait(2000); - if(Commons.isDisplayed(driver, By.id("dismissBtn"))) - Commons.click(driver, By.id("dismissBtn")); - else { + if(run==0) { Commons.click(driver, By.id("authorize_scope")); Commons.click(driver, By.id("voluntary_claims")); Commons.click(driver, By.id("continue")); Commons.click(driver, By.id("dismissBtn")); + run=1; + }else if(run==1) { + Commons.click(driver, By.id("dismissBtn")); } Commons.assertCheck(By.id("uinservices/viewhistory"),"verify if uin services login using perpetual vid");