diff options
author | William Carroll <wpcarro@gmail.com> | 2020-12-12T01·36+0000 |
---|---|---|
committer | William Carroll <wpcarro@gmail.com> | 2020-12-12T01·36+0000 |
commit | 686766929a659e611adea47d8368a691136b0336 (patch) | |
tree | 21811a0705bb8cb8f0da2cc2e1cb5066c3de1cae /assessments/semiprimes/server/test/math_test.exs | |
parent | ee96a818e104cad7c60947a905d0799c4dc13905 (diff) |
Simple Math tests
Calling `assert` within the `Enum.map` makes the errors more usable.
Diffstat (limited to 'assessments/semiprimes/server/test/math_test.exs')
-rw-r--r-- | assessments/semiprimes/server/test/math_test.exs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/assessments/semiprimes/server/test/math_test.exs b/assessments/semiprimes/server/test/math_test.exs index 81c60e40667e..c7186c824a8c 100644 --- a/assessments/semiprimes/server/test/math_test.exs +++ b/assessments/semiprimes/server/test/math_test.exs @@ -11,10 +11,8 @@ defmodule MathTest do {21, [3, 7]} ] |> Enum.map(fn {input, expected} -> - Math.factor(input) == expected + assert Math.factor(input) == expected end) - |> Enum.all?() - |> assert end test "handles large numbers" do |