Add credo to the project and:
- Run mix credo --all to identify possible code optimizations - Resolve most of the errors generated by credo such as: - Numbers larger than 9999 should be written with underscores: 58_127 - Modules should have a @moduledoc tag - Comparison will always return true
This commit is contained in:
@@ -39,7 +39,7 @@ defmodule FailureTests do
|
||||
|
||||
test "only offending lines are displayed for errors" do
|
||||
[koan] = SingleArity.all_koans()
|
||||
error = apply(SingleArity, koan, []) |> Tuple.to_list |> List.last |> error
|
||||
error = apply(SingleArity, koan, []) |> Tuple.to_list() |> List.last() |> error
|
||||
|
||||
assert Failure.format_failure(error) == """
|
||||
Assertion failed in some_file.ex:42\nmatch?(:foo, ___)
|
||||
|
||||
Reference in New Issue
Block a user