Link to Eurostar search page with pricing; add Bristol departures RTT link
Replace the Eurostar timetable link with the search URL (eurostar.com/search/uk-en?adult=1&origin=…&destination=…&outbound=…) so the footer links directly to the page that shows prices for the specific date and destination. Add a Bristol Temple Meads → Paddington departures link on RTT alongside the existing Paddington arrivals link. Also update "morning service unavailable" badge and tests to reflect the removal of the morning-only cutoff filter from find_unreachable_morning_eurostars. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
4e4202e220
commit
06afd57957
5 changed files with 27 additions and 8 deletions
|
|
@ -131,7 +131,9 @@ def test_connection_duration_in_trip():
|
|||
assert trips[0]['connection_duration'] == '1h 16m'
|
||||
|
||||
|
||||
def test_unreachable_morning_eurostars_lists_only_unreachable_morning_services():
|
||||
def test_find_unreachable_eurostars_excludes_connectable_services():
|
||||
# GWR arrives 08:45; default min=50/max=110 → viable window 09:35–10:35.
|
||||
# 09:30 too early, 10:15 connectable, 12:30 beyond max connection.
|
||||
gwr = [
|
||||
{'depart_bristol': '07:00', 'arrive_paddington': '08:45'},
|
||||
]
|
||||
|
|
@ -143,7 +145,7 @@ def test_unreachable_morning_eurostars_lists_only_unreachable_morning_services()
|
|||
|
||||
unreachable = find_unreachable_morning_eurostars(gwr, eurostar, DATE)
|
||||
|
||||
assert [service['depart_st_pancras'] for service in unreachable] == ['09:30']
|
||||
assert [s['depart_st_pancras'] for s in unreachable] == ['09:30', '12:30']
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
|
|
@ -205,7 +207,7 @@ def test_combine_trips_includes_ticket_fields():
|
|||
assert 'ticket_code' in t
|
||||
|
||||
|
||||
def test_unreachable_morning_eurostars_returns_empty_when_morning_service_is_reachable():
|
||||
def test_find_unreachable_eurostars_returns_empty_when_all_connectable():
|
||||
gwr = [
|
||||
{'depart_bristol': '07:00', 'arrive_paddington': '08:45'},
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue