Leon4gr45 commited on
Commit
3d89a09
·
verified ·
1 Parent(s): a5510ee

Delete test/support/conn_case.ex with huggingface_hub

Browse files
Files changed (1) hide show
  1. test/support/conn_case.ex +0 -48
test/support/conn_case.ex DELETED
@@ -1,48 +0,0 @@
1
- defmodule PlausibleWeb.ConnCase do
2
- @moduledoc """
3
- This module defines the test case to be used by
4
- tests that require setting up a connection.
5
-
6
- Such tests rely on `Phoenix.ConnTest` and also
7
- import other functionality to make it easier
8
- to build common data structures and query the data layer.
9
-
10
- Finally, if the test case interacts with the database,
11
- it cannot be async. For this reason, every test runs
12
- inside a transaction which is reset at the beginning
13
- of the test unless the test case is marked as async.
14
- """
15
-
16
- use ExUnit.CaseTemplate
17
-
18
- using do
19
- quote do
20
- use Plausible.TestUtils
21
- use Plausible
22
- use Plausible.Teams.Test
23
-
24
- import Plausible.Test.Support.HTML
25
- import Plug.Conn
26
- import Phoenix.ConnTest
27
-
28
- alias PlausibleWeb.Router.Helpers, as: Routes
29
- import Plausible.Factory
30
- import Plausible.AssertMatches
31
-
32
- @endpoint PlausibleWeb.Endpoint
33
- end
34
- end
35
-
36
- setup tags do
37
- :ok = Ecto.Adapters.SQL.Sandbox.checkout(Plausible.Repo)
38
-
39
- unless tags[:async] do
40
- Ecto.Adapters.SQL.Sandbox.mode(Plausible.Repo, {:shared, self()})
41
- end
42
-
43
- Plausible.Test.Support.Sandbox.allow_salts_process()
44
-
45
- conn = Phoenix.ConnTest.build_conn() |> Plausible.TestUtils.prepare_conn()
46
- {:ok, conn: conn}
47
- end
48
- end