summaryrefslogtreecommitdiff
path: root/test/support
diff options
context:
space:
mode:
Diffstat (limited to 'test/support')
-rw-r--r--test/support/conn_case.ex4
-rw-r--r--test/support/test_endpoint.ex25
-rw-r--r--test/support/test_router.ex10
3 files changed, 2 insertions, 37 deletions
diff --git a/test/support/conn_case.ex b/test/support/conn_case.ex
index bc28d10..e1ce056 100644
--- a/test/support/conn_case.ex
+++ b/test/support/conn_case.ex
@@ -24,10 +24,10 @@ defmodule MatrixAppServiceWeb.ConnCase do
import Phoenix.ConnTest
import MatrixAppServiceWeb.ConnCase
- alias MatrixAppServiceWeb.TestRouter.Helpers, as: Routes
+ alias MatrixAppServiceWeb.Router.Helpers, as: Routes
# The default endpoint for testing
- @endpoint MatrixAppServiceWeb.TestEndpoint
+ @endpoint MatrixAppServiceWeb.Endpoint
end
end
diff --git a/test/support/test_endpoint.ex b/test/support/test_endpoint.ex
deleted file mode 100644
index 5112df8..0000000
--- a/test/support/test_endpoint.ex
+++ /dev/null
@@ -1,25 +0,0 @@
-defmodule MatrixAppServiceWeb.TestEndpoint do
- use Phoenix.Endpoint, otp_app: :matrix_app_service
-
- # The session will be stored in the cookie and signed,
- # this means its contents can be read but not tampered with.
- # Set :encryption_salt if you would also like to encrypt it.
- @session_options [
- store: :cookie,
- key: "_matrix_app_service_key",
- signing_salt: "zE7AHynD"
- ]
-
- plug Plug.RequestId
- # plug Plug.Telemetry, event_prefix: [:phoenix, :endpoint]
-
- plug Plug.Parsers,
- parsers: [:urlencoded, :multipart, :json],
- pass: ["*/*"],
- json_decoder: Phoenix.json_library()
-
- plug Plug.MethodOverride
- plug Plug.Head
- plug Plug.Session, @session_options
- plug MatrixAppServiceWeb.TestRouter
-end
diff --git a/test/support/test_router.ex b/test/support/test_router.ex
deleted file mode 100644
index 3bbad03..0000000
--- a/test/support/test_router.ex
+++ /dev/null
@@ -1,10 +0,0 @@
-defmodule MatrixAppServiceWeb.TestRouter do
- require MatrixAppServiceWeb.Router
-
- use Phoenix.Router
-
- import Plug.Conn
- import Phoenix.Controller
-
- MatrixAppServiceWeb.Router.routes()
-end