Merge branch 'main' of /home/edward/git/eurotunnel-scrape

This commit is contained in:
Edward Betts 2023-09-03 15:48:12 +01:00
commit f9ce216a19

View file

@ -73,8 +73,8 @@ def run(playwright: Playwright) -> None:
page.get_by_role("cell", name="29").click() page.get_by_role("cell", name="29").click()
page.get_by_role("textbox", name="Return").click() page.get_by_role("textbox", name="Return").click()
page.get_by_role("row", name="September 2023").get_by_role("cell").nth(2).click() page.get_by_role("row", name="September 2023").get_by_role("cell").nth(1).click()
page.get_by_role("cell", name="6", exact=True).click() page.get_by_role("cell", name="13", exact=True).click()
page.get_by_role("button", name="Search and book").click() page.get_by_role("button", name="Search and book").click()
page.get_by_label("Enter your vehicle registration").fill("KE69HRR") page.get_by_label("Enter your vehicle registration").fill("KE69HRR")
@ -89,9 +89,7 @@ def run(playwright: Playwright) -> None:
page.locator("#slots div").filter(has_text="12:00To").locator("span").click() page.locator("#slots div").filter(has_text="12:00To").locator("span").click()
page.locator("div:nth-child(5) > .times > div:nth-child(2) > .radio-button").click() page.locator("div:nth-child(5) > .times > div:nth-child(2) > .radio-button").click()
page.locator( page.locator(".ticket:visible").first.click()
"div:nth-child(17) > .d-flex > div > .body > .radio-button"
).first.click()
page.get_by_role("button", name="Confirm and choose return ticket").click() page.get_by_role("button", name="Confirm and choose return ticket").click()
expect(page.get_by_text(return_label)).to_be_visible() expect(page.get_by_text(return_label)).to_be_visible()