Skip to content

Commit

Permalink
fix the tests
Browse files Browse the repository at this point in the history
  • Loading branch information
thecristen committed Jul 5, 2024
1 parent a2cef00 commit f4dfd3d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/dotcom_web/controllers/trip_plan_controller_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -812,7 +812,8 @@ defmodule DotcomWeb.TripPlanControllerTest do
end

test "doesn't set external_agency_name flag for regular routes", %{itineraries: itineraries} do
expect(Routes.Repo.Mock, :get, fn id ->
# called variable number of times, depending on the generated itineraries
stub(Routes.Repo.Mock, :get, fn id ->
%Routes.Route{id: id}
end)

Expand Down Expand Up @@ -840,9 +841,8 @@ defmodule DotcomWeb.TripPlanControllerTest do
%{i | legs: legs}
end)

# set up leg route to not be present in the V3 API, causing the fallback
# to populate the external_agency_name value
expect(Routes.Repo.Mock, :get, fn _ ->
# called variable number of times, depending on the generated itineraries
stub(Routes.Repo.Mock, :get, fn id ->
nil
end)

Expand Down

0 comments on commit f4dfd3d

Please sign in to comment.