Sha256: 9613166533a53b0ffa963fcee2ba1a372a4f0558f440891f06f789319790f4cf

Contents?: true

Size: 478 Bytes

Versions: 174

Compression:

Stored size: 478 Bytes

Contents

-module(luhn_tests).

-define(TESTED_MODULE, (sut(luhn))).
-define(TEST_VERSION, 1).
-include("exercism.hrl").


invalid_test() ->
  ?assertNot(?TESTED_MODULE:valid("1111")),
  ?assertNot(?TESTED_MODULE:valid("738")).

valid_test() ->
  ?assert(?TESTED_MODULE:valid("8739567")),
  ?assert(?TESTED_MODULE:valid("8763")),
  ?assert(?TESTED_MODULE:valid("2323 2005 7766 3554")).

create_test() ->
  ?assertEqual("2323 2005 7766 3554", ?TESTED_MODULE:create("2323 2005 7766 355")).

Version data entries

174 entries across 174 versions & 1 rubygems

Version Path
trackler-2.2.1.42 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.41 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.40 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.39 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.38 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.37 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.36 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.35 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.34 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.33 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.32 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.31 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.30 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.29 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.28 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.27 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.26 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.25 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.24 tracks/erlang/exercises/luhn/test/luhn_tests.erl
trackler-2.2.1.23 tracks/erlang/exercises/luhn/test/luhn_tests.erl