public bool isAllTicketsWithAirportCDG() { FindTicketsPage findTicketsPage = new FindTicketsPage(driver); HashSet <string> listAtributesTicketsWithAirportCDG = findTicketsPage.GetListAtributesTicketsWithAirportCDG(); return(listAtributesTicketsWithAirportCDG.Count != 0 ? listAtributesTicketsWithAirportCDG.Contains("CDG") && (listAtributesTicketsWithAirportCDG.Count == 1) : true); }
public bool isTiketsWithNewCity() { FindTicketsPage findTicketsPage = new FindTicketsPage(driver); HashSet <string> listAirports = findTicketsPage.GetListAtributesTicketsWithAirportCDG(); bool isValidAirport = true; foreach (string airport in listAirports) { isValidAirport = airport.Contains("LHR") || airport.Contains("LGW") || airport.Contains("LCY"); if (!isValidAirport) { break; } } return(isValidAirport); }