Files
elixir-koans/test/executor_test.exs
Ahmed Ismail edf50fdf80 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
2023-11-10 00:57:21 +05:00

18 lines
440 B
Elixir

defmodule ExecuteTest do
use ExUnit.Case
test "passes a koan" do
assert :passed == Execute.run_module(PassingKoan)
end
test "stops at the first failing koan" do
{:failed, %{file: file, line: line}, SampleKoan, _name} = Execute.run_module(SampleKoan)
assert file == 'test/support/sample_koan.ex'
assert line == 9
end
test "can access intro" do
assert SampleKoan.intro() == "There is something\n"
end
end