use credo style
This commit is contained in:
@ -116,7 +116,7 @@ defmodule LokalWeb.UserAuthTest do
|
||||
end
|
||||
|
||||
test "does not authenticate if data is missing", %{conn: conn, current_user: current_user} do
|
||||
_ = Accounts.generate_user_session_token(current_user)
|
||||
_session_token = Accounts.generate_user_session_token(current_user)
|
||||
conn = UserAuth.fetch_current_user(conn, [])
|
||||
refute get_session(conn, :user_token)
|
||||
refute conn.assigns.current_user
|
||||
|
@ -5,8 +5,7 @@ defmodule LokalWeb.UserConfirmationControllerTest do
|
||||
|
||||
use LokalWeb.ConnCase, async: true
|
||||
import LokalWeb.Gettext
|
||||
alias Lokal.Accounts
|
||||
alias Lokal.Repo
|
||||
alias Lokal.{Accounts, Repo}
|
||||
|
||||
@moduletag :user_confirmation_controller_test
|
||||
|
||||
|
@ -40,7 +40,7 @@ defmodule LokalWeb.InviteLiveTest do
|
||||
# |> form("#invite-form", invite: @invalid_attrs)
|
||||
# |> render_change() =~ dgettext("errors", "can't be blank")
|
||||
|
||||
{:ok, _, html} =
|
||||
{:ok, _live, html} =
|
||||
index_live
|
||||
|> form("#invite-form", invite: @create_attrs)
|
||||
|> render_submit()
|
||||
@ -64,7 +64,7 @@ defmodule LokalWeb.InviteLiveTest do
|
||||
# |> form("#invite-form", invite: @invalid_attrs)
|
||||
# |> render_change() =~ dgettext("errors", "can't be blank")
|
||||
|
||||
{:ok, _, html} =
|
||||
{:ok, _live, html} =
|
||||
index_live
|
||||
|> form("#invite-form", invite: @update_attrs)
|
||||
|> render_submit()
|
||||
|
@ -5,12 +5,11 @@ defmodule LokalWeb.ErrorViewTest do
|
||||
|
||||
use LokalWeb.ConnCase, async: true
|
||||
import LokalWeb.Gettext
|
||||
|
||||
@moduletag :error_view_test
|
||||
|
||||
# Bring render/3 and render_to_string/3 for testing custom views
|
||||
import Phoenix.View
|
||||
|
||||
@moduletag :error_view_test
|
||||
|
||||
test "renders 404.html" do
|
||||
assert render_to_string(LokalWeb.ErrorView, "404.html", []) =~
|
||||
dgettext("errors", "Not found")
|
||||
|
Reference in New Issue
Block a user