Skip to content

Commit

Permalink
Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
fabriziosestito committed Oct 13, 2022
1 parent 8c8dc4e commit 668fd95
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion test/wanda_web/controllers/catalog_controller_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ defmodule WandaWeb.CatalogControllerTest do
test "listing the checks catalog produces a CatalogResponse", %{conn: conn} do
json =
conn
|> get(Routes.catalog_path(conn, :list_catalog))
|> get(Routes.catalog_path(conn, :catalog))
|> json_response(200)

api_spec = ApiSpec.spec()
Expand Down
4 changes: 2 additions & 2 deletions test/wanda_web/views/catalog_view_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ defmodule WandaWeb.CatalogViewTest do
import Wanda.Factory

describe "CatalogView" do
test "renders list_catalog.json" do
test "renders catalog.json" do
checks = build_list(3, :check)

assert %{
items: ^checks
} = render(WandaWeb.CatalogView, "list_catalog.json", catalog: checks)
} = render(WandaWeb.CatalogView, "catalog.json", catalog: checks)
end
end
end
4 changes: 2 additions & 2 deletions test/wanda_web/views/result_view_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ defmodule WandaWeb.ListResultsViewTest do
alias Wanda.Results.ExecutionResult

describe "ResultView" do
test "renders list_results.json" do
test "renders index.json" do
inserted_at = DateTime.utc_now()

[
Expand Down Expand Up @@ -36,7 +36,7 @@ defmodule WandaWeb.ListResultsViewTest do
],
total_count: 10
} =
render(WandaWeb.ResultView, "list_results.json",
render(WandaWeb.ResultView, "index.json",
results: execution_results,
total_count: 10
)
Expand Down

0 comments on commit 668fd95

Please sign in to comment.