sloanelybutsurely.com/test/cms_web/controllers/error_json_test.exs
2025-02-20 10:43:58 -05:00

12 lines
338 B
Elixir

defmodule CMSWeb.ErrorJSONTest do
use CMSWeb.ConnCase, async: true
test "renders 404" do
assert CMSWeb.ErrorJSON.render("404.json", %{}) == %{errors: %{detail: "Not Found"}}
end
test "renders 500" do
assert CMSWeb.ErrorJSON.render("500.json", %{}) ==
%{errors: %{detail: "Internal Server Error"}}
end
end