import Config
# Only in tests, remove the complexity from the password hashing algorithm
config :bcrypt_elixir, :log_rounds, 1
# Configure your database
#
# The MIX_TEST_PARTITION environment variable can be used
# to provide built-in test partitioning in CI environment.
# Run `mix help test` for more information.
config :git_gud, GitGud.Repo,
username: "postgres",
password: "postgres",
hostname: "localhost",
database: "git_gud_test#{System.get_env("MIX_TEST_PARTITION")}",
pool: Ecto.Adapters.SQL.Sandbox,
pool_size: System.schedulers_online() * 2,
port: 54328
# We don't run a server during test. If one is required,
# you can enable the server option below.
config :git_gud, GitGudWeb.Endpoint,
http: [ip: {127, 0, 0, 1}, port: 4002],
secret_key_base: "IgyuwxR2+LcuHBvU9g0ZTv4WcKS7ZfbVrdalV6F6ivyZ7XZ3mRRiaxLT7wQ7yKNC",
server: false
# In test we don't send emails
config :git_gud, GitGud.Mailer, adapter: Swoosh.Adapters.Test
# Disable swoosh api client as it is only required for production adapters
config :swoosh, :api_client, false
# Print only warnings and errors during test
config :logger, level: :warning
# Initialize plugs at runtime for faster test compilation
config :phoenix, :plug_init_mode, :runtime
# Enable helpful, but potentially expensive runtime checks
config :phoenix_live_view,
enable_expensive_runtime_checks: true
# Sort query params output of verified routes for robust url comparisons
config :phoenix,
sort_verified_routes_query_params: true
# Oban runs in manual mode under tests so we can assert on enqueued jobs
# rather than racing the workers.
config :git_gud, Oban, testing: :manual
# Repos live under tmp during tests to keep them off the dev tree.
config :git_gud, GitGud.Repositories.Storage, base_path: Path.expand("../tmp/test/repos", __DIR__)
config :git_gud, GitGud.Storage, impl: GitGud.Storage.Disk
# The production default is :invite_only, but the test suite predates
# the invite gate and asserts the open-registration flow. Per-test
# `Application.put_env` overrides this for the explicit gating tests.
config :git_gud, registration_mode: :open
config :git_gud, GitGud.Storage.Disk,
root: Path.expand("../tmp/test/storage", __DIR__)
# Tests assert against an open federation graph; production defaults
# to allowlist (see GitGud.Federation moduledoc).
config :git_gud, GitGud.Federation, federation_mode: :open
2.3 KiB · text
5af55d9