freedive/test/freedive_web/controllers/error_json_test.exs

13 lines
358 B
Elixir
Raw Normal View History

2024-05-09 21:28:48 +02:00
defmodule FreediveWeb.ErrorJSONTest do
use FreediveWeb.ConnCase, async: true
test "renders 404" do
assert FreediveWeb.ErrorJSON.render("404.json", %{}) == %{errors: %{detail: "Not Found"}}
end
test "renders 500" do
assert FreediveWeb.ErrorJSON.render("500.json", %{}) ==
%{errors: %{detail: "Internal Server Error"}}
end
end