Esempio n. 1
0
 private List<Sale> getSalesList() {
   List<Sale> salesList = VPClient.getSalesList(driver);
   Iterator<Sale> iter = salesList.iterator();
   while (iter.hasNext()) {
     Sale sale = iter.next();
     if (sale.getName().contains("One Day") || sale.getDatesSale().startsWith("A partir")) {
       iter.remove();
     }
   }
   return salesList;
 }
Esempio n. 2
0
 @Test
 public void testGetSalesList() {
   List<Sale> salesList = VPClient.getSalesList(driver);
   assertFalse(salesList.isEmpty());
   Sale sale = salesList.get(0);
   // System.out.println(driver.getPageSource());
   assertNotNull(sale.getLink());
   assertNotNull(sale.getDatesSale());
   System.out.println(salesList);
   for (Sale otherSale : salesList) {
     assertFalse(sale.getName().isEmpty());
     String dateSales = otherSale.getDatesSale();
     System.out.println(dateSales);
     assertFalse(dateSales.isEmpty());
   }
 }