livebook/config/test.exs

32 lines
870 B
Elixir
Raw Normal View History

import Config
2021-01-08 03:55:45 +08:00
# We don't run a server during test. If one is required,
# you can enable the server option below.
config :livebook, LivebookWeb.Endpoint,
2021-01-08 03:55:45 +08:00
http: [port: 4002],
server: false
# Print only warnings and errors during test
2022-08-03 20:32:32 +08:00
config :logger, level: :warning
# Disable authentication mode during test
config :livebook,
authentication_mode: :disabled,
check_completion_data_interval: 300,
iframe_port: 4003
data_path = Path.expand("tmp/livebook_data/test")
# Clear data path for tests
if File.exists?(data_path) do
File.rm_rf!(data_path)
end
config :livebook, :data_path, data_path
2022-08-24 23:35:28 +08:00
# Use longnames when running tests in CI, so that no host resolution is required,
# see https://github.com/livebook-dev/livebook/pull/173#issuecomment-819468549
if System.get_env("CI") == "true" do
config :livebook, :node, {:longnames, :"livebook@127.0.0.1"}
end