@Test(groups = {"Checkout", "CC", "Acquisition", "Payments"}) public void verifyAcqCheckoutWithJCB() { Assert.assertTrue( driver.getCurrentUrl().contains("/estore/checkOut"), "User is not landing to acquisition page"); checkOutPage.fillLoginData(); Assert.assertTrue( checkOutPage.welcomeUserText.isDisplayed(), "Welcome user head is not present"); checkOutPage.fillBillingPaymentInfo(cardType, false, false); Assert.assertTrue(checkOutPage.jcbIcon.isDisplayed(), cardType + " Icon is not present"); Assert.assertTrue( checkOutPage.miniPaymentImg(cardType).isDisplayed(), cardType + " img in mini cart is not present"); checkOutPage.nextBtn.click(); sleep(5000); Assert.assertTrue( checkOutPage.paymentName(cardType).isDisplayed(), cardType + " payment method is not present"); Assert.assertEquals( "Agree and Place Your Order", checkOutPage.confirmSubmitBtn.getAttribute("value"), "Agree and Place Your Order btn is not present"); checkOutPage.waitAndClick(checkOutPage.confirmSubmitBtn); waitForPageToLoad(); Assert.assertTrue( confirmPage.pageKey.isDisplayed(), "User is not landing to confirm order online page : wrong page key "); Assert.assertTrue( driver.getCurrentUrl().contains("confirmationOrderOnline"), "User is not landing to confirm order online page"); orderNumber = confirmPage.getOrderNum(); // Login to CSR csrSignInPage.logIn(orderNumber); csrSearchPage.orderNumTextField.sendKeys(orderNumber); csrSearchPage.searchBtn.click(); Assert.assertTrue( viewOrderPage.orderNum(orderNumber).isDisplayed(), "View Order : " + orderNumber + " is not in search list"); Assert.assertTrue( viewOrderPage.orderStatus("CLOSED").isDisplayed(), "View Order : order status is not CLOSED"); Assert.assertTrue( viewOrderPage.orderSubState("EMPTY").isDisplayed(), "View Order : order sub-state is not EMPTY"); }