update to phoenix 1.6
This commit is contained in:
		| @@ -1,3 +1,8 @@ | ||||
| defmodule CanneryWeb.HomeViewTest do | ||||
|   use CanneryWeb.ConnCase, async: true | ||||
|  | ||||
|   # When testing helpers, you may want to import Phoenix.HTML and | ||||
|   # use functions such as safe_to_string() to convert the helper | ||||
|   # result into an HTML string. | ||||
|   # import Phoenix.HTML | ||||
| end | ||||
|   | ||||
| @@ -29,12 +29,8 @@ defmodule CanneryWeb.ChannelCase do | ||||
|   end | ||||
|  | ||||
|   setup tags do | ||||
|     :ok = Ecto.Adapters.SQL.Sandbox.checkout(Cannery.Repo) | ||||
|  | ||||
|     unless tags[:async] do | ||||
|       Ecto.Adapters.SQL.Sandbox.mode(Cannery.Repo, {:shared, self()}) | ||||
|     end | ||||
|  | ||||
|     pid = Ecto.Adapters.SQL.Sandbox.start_owner!(Cannery.Repo, shared: not tags[:async]) | ||||
|     on_exit(fn -> Ecto.Adapters.SQL.Sandbox.stop_owner(pid) end) | ||||
|     :ok | ||||
|   end | ||||
| end | ||||
|   | ||||
| @@ -32,12 +32,8 @@ defmodule CanneryWeb.ConnCase do | ||||
|   end | ||||
|  | ||||
|   setup tags do | ||||
|     :ok = Ecto.Adapters.SQL.Sandbox.checkout(Cannery.Repo) | ||||
|  | ||||
|     unless tags[:async] do | ||||
|       Ecto.Adapters.SQL.Sandbox.mode(Cannery.Repo, {:shared, self()}) | ||||
|     end | ||||
|  | ||||
|     pid = Ecto.Adapters.SQL.Sandbox.start_owner!(Cannery.Repo, shared: not tags[:async]) | ||||
|     on_exit(fn -> Ecto.Adapters.SQL.Sandbox.stop_owner(pid) end) | ||||
|     {:ok, conn: Phoenix.ConnTest.build_conn()} | ||||
|   end | ||||
|  | ||||
|   | ||||
| @@ -28,12 +28,8 @@ defmodule Cannery.DataCase do | ||||
|   end | ||||
|  | ||||
|   setup tags do | ||||
|     :ok = Ecto.Adapters.SQL.Sandbox.checkout(Cannery.Repo) | ||||
|  | ||||
|     unless tags[:async] do | ||||
|       Ecto.Adapters.SQL.Sandbox.mode(Cannery.Repo, {:shared, self()}) | ||||
|     end | ||||
|  | ||||
|     pid = Ecto.Adapters.SQL.Sandbox.start_owner!(Cannery.Repo, shared: not tags[:async]) | ||||
|     on_exit(fn -> Ecto.Adapters.SQL.Sandbox.stop_owner(pid) end) | ||||
|     :ok | ||||
|   end | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user