コード例 #1
0
 @Then("^total amount in basket equals £([\\.0-9]+)")
 public void total_amount_in_basket_equals_£_expectedPrice(String expectedPrice) throws Throwable {
   PromotionSubPage promotionSubPage = new PromotionSubPage(getDriver());
   assertThat(promotionSubPage.getBasketSummaryTotal())
       .isEqualByComparingTo(new BigDecimal(expectedPrice));
 }
コード例 #2
0
 @And("^any (\\d+) are added to basket$")
 public void any_noOfItems_are_added_to_basket(int noOfItems) throws Throwable {
   PromotionSubPage promotionSubPage = new PromotionSubPage(getDriver());
   promotionSubPage.addFirstNProducts(noOfItems);
 }