Skip to content

Commit e3b4af7

Browse files
dkarterjwworth
authored andcommittedSep 6, 2019
Add test coverage report via coveralls.io
1 parent 0507fee commit e3b4af7

File tree

6 files changed

+28
-3
lines changed

6 files changed

+28
-3
lines changed
 

‎.circleci/config.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,6 @@ jobs:
2424
- run: mix phx.digest
2525
- run: mix format --check-formatted
2626
- run: mix credo
27-
- run: mix test
27+
- run: mix coveralls.circle
2828
- store_artifacts:
2929
path: /home/circleci/tilex/screenshots

‎.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -30,5 +30,8 @@ erl_crash.dump
3030

3131
/tmp
3232

33+
# coveralls output
34+
/cover
35+
3336
/priv/static/js/app.js
3437
/priv/static/js/app.js.map

‎README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Tilex - Today I Learned in Elixir
22

3-
[![CircleCI](https://circleci.com/gh/hashrocket/tilex.svg?style=svg)](https://circleci.com/gh/hashrocket/tilex)
3+
[![CircleCI](https://circleci.com/gh/hashrocket/tilex.svg?style=svg)](https://circleci.com/gh/hashrocket/tilex) [![Coverage Status](https://coveralls.io/repos/github/hashrocket/tilex/badge.svg?branch=master)](https://coveralls.io/github/hashrocket/tilex?branch=master)
44

55
> Today I Learned is an open-source project by the team at
66
> [Hashrocket](https://hashrocket.com/) that catalogues the sharing &

‎coveralls.json

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"skip_files": [
3+
"lib/mix/tasks",
4+
"lib/test",
5+
"lib/tilex/repo.ex",
6+
"lib/tilex_web.ex",
7+
"lib/tilex_web/channels/user_socket.ex",
8+
"lib/tilex_web/endpoint.ex",
9+
"lib/tilex_web/gettext.ex",
10+
"lib/tilex_web/router.ex",
11+
"test/support"
12+
]
13+
}

‎mix.exs

+9-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,14 @@ defmodule Tilex.Mixfile do
1111
build_embedded: Mix.env() == :prod,
1212
start_permanent: Mix.env() == :prod,
1313
aliases: aliases(),
14-
deps: deps()
14+
deps: deps(),
15+
test_coverage: [tool: ExCoveralls],
16+
preferred_cli_env: [
17+
coveralls: :test,
18+
"coveralls.detail": :test,
19+
"coveralls.post": :test,
20+
"coveralls.html": :test
21+
]
1522
]
1623
end
1724

@@ -38,6 +45,7 @@ defmodule Tilex.Mixfile do
3845
{:credo, "~> 1.1.0", only: [:dev, :test], runtime: false},
3946
{:earmark, "~> 1.3.2"},
4047
{:ecto_sql, "~> 3.0"},
48+
{:excoveralls, "~> 0.10", only: :test},
4149
{:extwitter, "~> 0.8"},
4250
{:floki, "~> 0.21.0"},
4351
{:gettext, "~> 0.13"},

‎mix.lock

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
"ecto": {:hex, :ecto, "3.1.7", "fa21d06ef56cdc2fdaa62574e8c3ba34a2751d44ea34c30bc65f0728421043e5", [:mix], [{:decimal, "~> 1.6", [hex: :decimal, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}], "hexpm"},
1919
"ecto_sql": {:hex, :ecto_sql, "3.1.6", "1e80e30d16138a729c717f73dcb938590bcdb3a4502f3012414d0cbb261045d8", [:mix], [{:db_connection, "~> 2.0", [hex: :db_connection, repo: "hexpm", optional: false]}, {:ecto, "~> 3.1.0", [hex: :ecto, repo: "hexpm", optional: false]}, {:mariaex, "~> 0.9.1", [hex: :mariaex, repo: "hexpm", optional: true]}, {:myxql, "~> 0.2.0", [hex: :myxql, repo: "hexpm", optional: true]}, {:postgrex, "~> 0.14.0 or ~> 0.15.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm"},
2020
"eternal": {:hex, :eternal, "1.2.1", "d5b6b2499ba876c57be2581b5b999ee9bdf861c647401066d3eeed111d096bc4", [:mix], [], "hexpm"},
21+
"excoveralls": {:hex, :excoveralls, "0.11.2", "0c6f2c8db7683b0caa9d490fb8125709c54580b4255ffa7ad35f3264b075a643", [:mix], [{:hackney, "~> 1.0", [hex: :hackney, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm"},
2122
"extwitter": {:hex, :extwitter, "0.8.0", "1de29ba0b75c9cdbbbb936302ebfae2635ab42b6530a404c0e24f7acfe062fc1", [:mix], [{:oauther, "~> 1.1", [hex: :oauther, repo: "hexpm", optional: false]}, {:poison, "~> 2.0", [hex: :poison, repo: "hexpm", optional: false]}], "hexpm"},
2223
"file_system": {:hex, :file_system, "0.2.7", "e6f7f155970975789f26e77b8b8d8ab084c59844d8ecfaf58cbda31c494d14aa", [:mix], [], "hexpm"},
2324
"floki": {:hex, :floki, "0.21.0", "0c0191a6dbc559300bac232f716c55fb5738d45ae846b3141b19e5f5741c1907", [:mix], [{:html_entities, "~> 0.4.0", [hex: :html_entities, repo: "hexpm", optional: false]}, {:mochiweb, "~> 2.15", [hex: :mochiweb, repo: "hexpm", optional: false]}], "hexpm"},

0 commit comments

Comments
 (0)
Please sign in to comment.