This commit is contained in:
Simon Prévost 2019-07-22 13:21:47 -04:00
parent 215f93dbaf
commit 39753e63e5
2 changed files with 7 additions and 6 deletions

View File

@ -33,10 +33,11 @@ defmodule Accent.WebAppController do
|> halt()
{:ok, content} ->
content = content
|> String.replace("__WEBAPP_AUTH_PROVIDERS__", "dummy")
|> String.replace("__API_HOST__", "http://localhost:4008")
|> String.replace("__API_WS_HOST__", "ws://localhost:4008")
content =
content
|> String.replace("__WEBAPP_AUTH_PROVIDERS__", "dummy")
|> String.replace("__API_HOST__", "http://localhost:4008")
|> String.replace("__API_WS_HOST__", "ws://localhost:4008")
assign(conn, :file, content)
end

View File

@ -7,7 +7,7 @@ defmodule AccentTest.WebappController do
|> get(web_app_path(conn, []))
assert response.status == 200
assert response.state == :file
assert response.state == :sent
assert get_resp_header(response, "content-type") == ["text/html; charset=utf-8"]
end
@ -17,7 +17,7 @@ defmodule AccentTest.WebappController do
|> get("/app/foo")
assert response.status == 200
assert response.state == :file
assert response.state == :sent
assert get_resp_header(response, "content-type") == ["text/html; charset=utf-8"]
end
end