Browse Source

test: fix preloading issues

main
Inhji Y. 7 months ago
parent
commit
bf93b32373
  1. 2
      test/mirage/lists_test.exs
  2. 2
      test/mirage/notes_test.exs
  3. 2
      test/mirage_web/controllers/setting_controller_test.exs

2
test/mirage/lists_test.exs

@ -16,7 +16,9 @@ defmodule Mirage.ListsTest do
|> Enum.into(@valid_attrs)
|> Lists.create_list()
list
|> Lists.preload_list()
end
test "list_lists/0 returns all lists" do

2
test/mirage/notes_test.exs

@ -57,7 +57,7 @@ defmodule Mirage.NotesTest do
title = Notes.today_title()
assert Notes.get_note_by_title(title) == nil
[note] = Notes.list_notes(:today)
assert Notes.get_note_by_title(title) == note
assert Notes.get_note_by_title(title) |> Notes.preload_note() == note
end
test "get_note!/1 returns the note with given id" do

2
test/mirage_web/controllers/setting_controller_test.exs

@ -17,7 +17,7 @@ defmodule MirageWeb.SettingControllerTest do
describe "index" do
test "lists all settings", %{conn: conn} do
conn = get(conn, Routes.setting_path(conn, :index))
assert html_response(conn, 200) =~ "Listing Settings"
assert html_response(conn, 200) =~ "Settings"
end
end

Loading…
Cancel
Save