summaryrefslogtreecommitdiff
path: root/mix.exs
diff options
context:
space:
mode:
authorILYA Khlopotov <iilyak@apache.org>2019-05-09 21:49:32 +0000
committerILYA Khlopotov <iilyak@apache.org>2019-07-29 11:24:37 +0000
commitd5849629a99603904ce94ce561916ebb66d04600 (patch)
tree984ff4894dfd67969ca002e39435f9988ed7cf5f /mix.exs
parentf33378b38e45629c5934e739835571fbbd28bdda (diff)
downloadcouchdb-d5849629a99603904ce94ce561916ebb66d04600.tar.gz
Minimal ExUnit setup
Diffstat (limited to 'mix.exs')
-rw-r--r--mix.exs47
1 files changed, 47 insertions, 0 deletions
diff --git a/mix.exs b/mix.exs
new file mode 100644
index 000000000..d9c8c2160
--- /dev/null
+++ b/mix.exs
@@ -0,0 +1,47 @@
+defmodule CouchDBTest.Mixfile do
+ use Mix.Project
+
+ def project do
+ [
+ app: :couchdbtest,
+ version: "0.1.0",
+ elixir: "~> 1.5",
+ lockfile: Path.expand("mix.lock", __DIR__),
+ deps_path: Path.expand("src", __DIR__),
+ build_path: Path.expand("_build", __DIR__),
+ compilers: [:elixir, :app],
+ start_permanent: Mix.env() == :prod,
+ build_embedded: Mix.env() == :prod,
+ deps: deps(),
+ consolidate_protocols: Mix.env() not in [:test, :dev],
+ test_paths: get_test_paths(),
+ elixirc_paths: elixirc_paths(Mix.env())
+ ]
+ end
+
+ # Run "mix help compile.app" to learn about applications.
+ def application do
+ [
+ extra_applications: [:logger]
+ ]
+ end
+
+ # Specifies which paths to compile per environment.
+ defp elixirc_paths(:test), do: ["test/elixir/lib", "test/elixir/test/support"]
+ defp elixirc_paths(_), do: ["test/elixir/lib"]
+
+ # Run "mix help deps" to learn about dependencies.
+ defp deps() do
+ [
+ {:httpotion, "~> 3.0", only: [:dev, :test], runtime: false},
+ {:jiffy, path: Path.expand("src/jiffy", __DIR__)},
+ {:ibrowse,
+ path: Path.expand("src/ibrowse", __DIR__), override: true, compile: false},
+ {:credo, "~> 1.0.0", only: [:dev, :test], runtime: false}
+ ]
+ end
+
+ def get_test_paths do
+ Path.wildcard("src/*/test/exunit") |> Enum.filter(&File.dir?/1)
+ end
+end