From 5bf8b50e2dba51aa14194c0d0a077b569bfb796c Mon Sep 17 00:00:00 2001 From: Sloane Perrault Date: Sun, 2 Jul 2023 08:20:19 -0400 Subject: [PATCH] 0.1.0 --- lib/type_id.ex | 2 +- mix.exs | 2 +- test/spec_test.exs | 11 ++++++----- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/lib/type_id.ex b/lib/type_id.ex index c3e2708..36ff22c 100644 --- a/lib/type_id.ex +++ b/lib/type_id.ex @@ -153,7 +153,7 @@ defmodule TypeID do [suffix] -> from!("", suffix) - _ -> + _ -> raise ArgumentError, "invalid TypeID" end end diff --git a/mix.exs b/mix.exs index 8c28a6e..8cebe70 100644 --- a/mix.exs +++ b/mix.exs @@ -4,7 +4,7 @@ defmodule TypeID.MixProject do def project do [ app: :typeid_elixir, - version: "0.0.1", + version: "0.1.0", elixir: "~> 1.15", start_permanent: Mix.env() == :prod, description: description(), diff --git a/test/spec_test.exs b/test/spec_test.exs index 126e04f..e1eeeb7 100644 --- a/test/spec_test.exs +++ b/test/spec_test.exs @@ -1,16 +1,17 @@ defmodule TypeID.SpecTest do use ExUnit.Case - specs_path = :code.priv_dir(:typeid_elixir) - |> Path.join("/spec") + specs_path = + :code.priv_dir(:typeid_elixir) + |> Path.join("/spec") @valid_specs specs_path |> Path.join("/valid.yml") |> YamlElixir.read_from_file!() @invalid_specs specs_path - |> Path.join("/invalid.yml") - |> YamlElixir.read_from_file!() + |> Path.join("/invalid.yml") + |> YamlElixir.read_from_file!() describe "valid" do for %{"name" => name, "typeid" => typeid, "prefix" => prefix, "uuid" => uuid} <- @valid_specs do @@ -23,7 +24,7 @@ defmodule TypeID.SpecTest do end describe "invalid" do - for %{"name" => name, "typeid" => typeid, "description" => desc } <- @invalid_specs do + for %{"name" => name, "typeid" => typeid, "description" => desc} <- @invalid_specs do test "#{name}: #{desc}" do assert :error = TypeID.from_string(unquote(typeid)) end