Merge branch 'fix-tags' into 'develop'
[akkoma] / config / test.exs
1 use Mix.Config
2
3 # We don't run a server during test. If one is required,
4 # you can enable the server option below.
5 config :pleroma, Pleroma.Web.Endpoint,
6 http: [port: 4001],
7 url: [port: 4001],
8 server: true
9
10 # Print only warnings and errors during test
11 config :logger, level: :warn
12
13 config :pleroma, Pleroma.Uploaders.Local, uploads: "test/uploads"
14
15 config :pleroma, Pleroma.Mailer, adapter: Swoosh.Adapters.Test
16
17 # Configure your database
18 config :pleroma, Pleroma.Repo,
19 adapter: Ecto.Adapters.Postgres,
20 username: "postgres",
21 password: "postgres",
22 database: "pleroma_test",
23 hostname: System.get_env("DB_HOST") || "localhost",
24 pool: Ecto.Adapters.SQL.Sandbox
25
26 # Reduce hash rounds for testing
27 config :pbkdf2_elixir, rounds: 1
28
29 config :pleroma, :websub, Pleroma.Web.WebsubMock
30 config :pleroma, :ostatus, Pleroma.Web.OStatusMock
31 config :tesla, adapter: Tesla.Mock
32
33 config :web_push_encryption, :vapid_details,
34 subject: "mailto:administrator@example.com",
35 public_key:
36 "BLH1qVhJItRGCfxgTtONfsOKDc9VRAraXw-3NsmjMngWSh7NxOizN6bkuRA7iLTMPS82PjwJAr3UoK9EC1IFrz4",
37 private_key: "_-XZ0iebPrRfZ_o0-IatTdszYa8VCH1yLN-JauK7HHA"
38
39 try do
40 import_config "test.secret.exs"
41 rescue
42 _ ->
43 IO.puts(
44 "You may want to create test.secret.exs to declare custom database connection parameters."
45 )
46 end