Skip to content

Commit

Permalink
setup --> setup_all and File.write! --> File.write
Browse files Browse the repository at this point in the history
  • Loading branch information
kelseyroy committed Jul 20, 2023
1 parent a6336f9 commit 99b55fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/http_to_do_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ defmodule HTTPServerTest.ToDo do
"lib/http_server_test_fixture/mock_data/test-data.json"
)

setup do
setup_all do
act_arrange_test_todo = JSON.encode!(%{"1" => %{"todo1" => "Act"}, "2" => %{"todo2" => "Arrange"}})
File.write!(@file_path, act_arrange_test_todo)
File.write(@file_path, act_arrange_test_todo)
on_exit(fn -> if File.exists?(@file_path), do: File.rm!(@file_path) end)
:ok
end
Expand Down

0 comments on commit 99b55fb

Please sign in to comment.