Closed TrailingDots closed 1 year ago
Updated to latest excoveralls:
{:excoveralls, "~> 0.10", only: :test},
Now works like a charm. Sorry - I missed this! :(
Coveralls crash
I have a newly installed erlang and elixir system downloaded from Erlang Solutions.
This is my new computer that runs Ubuntu 20.04.4 (Focal) 64-bit with Gnome 3.36.8.
The code under test and coverage has successfully run on my older computer (sadly dead).
Both _build and deps dirs were removed and 'mix deps.get run to install the latest dependencies.
The config dir is empty.
The coverall.json file contains:
{ "skip_files": [ "test", "deps" ] }
The elixir and erlang versions:
elixir --version Erlang/OTP 24 [erts-12.3] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] [jit] Elixir 1.13.0 (compiled with Erlang/OTP 24) (base) cecilm@mercury 2 lil_schemer (master))
The mix.exs relevant to coverage:
... # Run: MIX_ENV=test mix coveralls.html # Then the html output is in cover/excoveralls.html test_coverage: [tool: ExCoveralls], preferred_cli_env: [ coveralls: :test, "coveralls.detail": :test, "coveralls.post": :test, "coveralls.html": :test ] ... defp deps do [ {:ex_doc, "~> 0.19"}, {:httpoison, "~> 1.0.0"}, {:earmark, "~> 1.2.4"}, {:excoveralls, "~> 0.10", only: :test}, {:credo, "~> 1.0", only: [:dev, :test], runtime: false}, {:dialyxir, "~> 0.5", only: [:dev], runtime: false}, ] end
When I attempt to get code coverage for code that compiles and successfully passes all tests the result crashes:
MIX_ENV=test mix coveralls ....................................................... Finished in 0.3 seconds (0.00s async, 0.3s sync) 11 doctests, 44 tests, 0 failures Randomized with seed 533597 ** (FunctionClauseError) no function clause matching in IO.chardata_to_string/1 The following arguments were given to IO.chardata_to_string/1: # 1 nil Attempted function clauses (showing 2 out of 2): def chardata_to_string(string) when is_binary(string) def chardata_to_string(list) when is_list(list) (elixir 1.13.0) lib/io.ex:627: IO.chardata_to_string/1 (elixir 1.13.0) lib/path.ex:423: Path.dirname/1 (excoveralls 0.12.3) lib/excoveralls/cover.ex:21: ExCoveralls.Cover.module_path/1 (excoveralls 0.12.3) lib/excoveralls/stats.ex:54: ExCoveralls.Stats.add_counts/4 (elixir 1.13.0) lib/enum.ex:2396: Enum."-reduce/3-lists^foldl/2-0-"/3 (excoveralls 0.12.3) lib/excoveralls/stats.ex:28: ExCoveralls.Stats.report/1 (excoveralls 0.12.3) lib/excoveralls.ex:43: ExCoveralls.execute/2 (mix 1.13.0) lib/mix/tasks/test.ex:538: Mix.Tasks.Test.do_run/3 (mix 1.13.0) lib/mix/task.ex:397: anonymous fn/3 in Mix.Task.run_task/3 (excoveralls 0.12.3) lib/mix/tasks.ex:54: Mix.Tasks.Coveralls.do_run/2 (mix 1.13.0) lib/mix/task.ex:397: anonymous fn/3 in Mix.Task.run_task/3 (mix 1.13.0) lib/mix/cli.ex:84: Mix.CLI.run_task/2 (elixir 1.13.0) lib/code.ex:1183: Code.require_file/2
this issue has already been resolved on #273
@parroty kindly, this issue could be closed, as mentioned by the OP.
Thank you for the follow-up. I'll be closing the issue.
Updated to latest excoveralls:
Now works like a charm. Sorry - I missed this! :(
============================ How do I close this bug report?
Coveralls crash
I have a newly installed erlang and elixir system downloaded from Erlang Solutions.
This is my new computer that runs Ubuntu 20.04.4 (Focal) 64-bit with Gnome 3.36.8.
The code under test and coverage has successfully run on my older computer (sadly dead).
Both _build and deps dirs were removed and 'mix deps.get run to install the latest dependencies.
The config dir is empty.
The coverall.json file contains:
The elixir and erlang versions:
The mix.exs relevant to coverage:
When I attempt to get code coverage for code that compiles and successfully passes all tests the result crashes: