Sha256: 3871823eb74a0ecfbaa7336996ad143c43c2554478d784c8cbafe75591e4c28d

Contents?: true

Size: 593 Bytes

Versions: 326

Compression:

Stored size: 593 Bytes

Contents

if !System.get_env("EXERCISM_TEST_EXAMPLES") do
  Code.load_file("nth_prime.exs", __DIR__)
end

ExUnit.start
ExUnit.configure exclude: :pending, trace: true

defmodule NthPrimeTest do
  use ExUnit.Case

  # @tag :pending
  test "first prime" do
    assert Prime.nth(1) == 2
  end

  @tag :pending
  test "second prime" do
    assert Prime.nth(2) == 3
  end

  @tag :pending
  test "sixth prime" do
    assert Prime.nth(6) == 13
  end

  @tag :pending
  test "100th prime" do
    assert Prime.nth(100) == 541
  end

  @tag :pending
  test "weird case" do
    catch_error Prime.nth(0)
  end
end

Version data entries

326 entries across 326 versions & 1 rubygems

Version Path
trackler-2.2.1.109 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.108 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.107 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.106 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.105 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.104 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.103 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.102 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.101 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.100 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.99 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.98 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.97 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.96 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.95 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.94 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.93 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.92 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.91 tracks/elixir/exercises/nth-prime/nth_prime_test.exs
trackler-2.2.1.90 tracks/elixir/exercises/nth-prime/nth_prime_test.exs