<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>src/smak_test.erl</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -10,7 +10,7 @@ erl: ebin lib
 	-eval 'case make:all() of up_to_date -&gt; halt(0); error -&gt; halt(1) end.'
 
 docs:
-	@erl -noshell -run edoc_run application '$(APP)' '&quot;.&quot;' '[]'
+	@$(ERL) -noshell -run edoc_run application '$(APP)' '&quot;.&quot;' '[]'
 
 clean:
 	@echo &quot;removing:&quot;
@@ -27,3 +27,7 @@ lib:
 
 dialyzer: erl
 	@dialyzer -c ebin
+
+test: erl
+	@$(ERL) -pa $(EBIN_DIRS) -pa ebin -noinput +B \
+	-eval 'case lists:member(error, smak_test:test()) of true -&gt; halt(1); _ -&gt; halt(0) end.'</diff>
      <filename>Makefile</filename>
    </modified>
    <modified>
      <diff>@@ -74,6 +74,7 @@
          defrag/1]).
 
 -include(&quot;smak.hrl&quot;).
+-include_lib(&quot;eunit/include/eunit.hrl&quot;).
 
 -define(IS_ALWAYS_SAFE(C), (((C &gt;= $A) and (C =&lt; $Z))
                             or ((C &gt;= $a) and (C =&lt; $z))
@@ -453,45 +454,34 @@ defrag(Url) when is_list(Url) -&gt;
 
 %% TODO: Move this to eunit or something useful
 -define(_TEST_BASE, &quot;http://a/b/c/d&quot;).
--define(TESTS, [{&quot;g:h&quot;, [?_TEST_BASE, &quot;g:h&quot;]},
-                {&quot;http://a/b/c/g&quot;, [?_TEST_BASE, &quot;http:g&quot;]},
-                {&quot;http://a/b/c/d&quot;, [?_TEST_BASE, &quot;http:&quot;]},
-                {&quot;http://a/b/c/g&quot;, [?_TEST_BASE, &quot;g&quot;]},
-                {&quot;http://a/b/c/g&quot;, [?_TEST_BASE, &quot;./g&quot;]},
-                {&quot;http://a/b/c/g/&quot;, [?_TEST_BASE, &quot;g/&quot;]},
-                {&quot;http://a/g&quot;, [?_TEST_BASE, &quot;/g&quot;]},
-                {&quot;http://g&quot;, [?_TEST_BASE, &quot;//g&quot;]}, %% Error
-                {&quot;http://a/b/c/d?y&quot;, [?_TEST_BASE, &quot;?y&quot;]},
-                {&quot;http://a/b/c/g?y&quot;, [?_TEST_BASE, &quot;g?y&quot;]},
-                {&quot;http://a/b/c/g?y/./x&quot;, [?_TEST_BASE, &quot;g?y/./x&quot;]},
-                {&quot;http://a/b/c/&quot;, [?_TEST_BASE, &quot;.&quot;]},
-                {&quot;http://a/b/c/&quot;, [?_TEST_BASE, &quot;./&quot;]},
-                {&quot;http://a/b/&quot;, [?_TEST_BASE, &quot;..&quot;]}, %% Error
-                {&quot;http://a/b/&quot;, [?_TEST_BASE, &quot;../&quot;]},
-                {&quot;http://a/b/g&quot;, [?_TEST_BASE, &quot;../g&quot;]},
-                {&quot;http://a/&quot;, [?_TEST_BASE, &quot;../..&quot;]},
-                {&quot;http://a/g&quot;, [?_TEST_BASE, &quot;../../g&quot;]}, %% Error
-                {&quot;http://a/../g&quot;, [?_TEST_BASE, &quot;../../../g&quot;]}, %% Error
-                {&quot;http://a/b/g&quot;, [?_TEST_BASE, &quot;./../g&quot;]},
-                {&quot;http://a/b/c/g/&quot;, [?_TEST_BASE, &quot;./g/.&quot;]},
-                {&quot;http://a/./g&quot;, [?_TEST_BASE, &quot;/./g&quot;]},
-                {&quot;http://a/b/c/g/h&quot;, [?_TEST_BASE, &quot;g/./h&quot;]},
-                {&quot;http://a/b/c/h&quot;, [?_TEST_BASE, &quot;g/../h&quot;]}, %% Error
-                {&quot;http://a/b/c/g&quot;, [?_TEST_BASE, &quot;http:g&quot;]},
-                {&quot;http://a/b/c/d&quot;, [?_TEST_BASE, &quot;http:&quot;]},
-                {&quot;http://a/b/c/d?y&quot;, [?_TEST_BASE, &quot;http:?y&quot;]},
-                {&quot;http://a/b/c/g?y&quot;, [?_TEST_BASE, &quot;http:g?y&quot;]},
-                {&quot;http://a/b/c/g?y/./x&quot;, [?_TEST_BASE, &quot;http:g?y/./x&quot;]}].
-
-test() -&gt;
-    lists:map(fun({Result, Args}) -&gt;
-                      io:format(&quot;~p = join(~p)...&quot;, [Result, Args]),
-                      case apply(?MODULE, join, Args) of
-                          Result -&gt;
-                              io:format(&quot;ok~n&quot;),
-                              ok;
-                          Err -&gt;
-                              io:format(&quot;ERROR (got ~p)~n&quot;, [Err]),
-                              {error, Err}
-                      end
-              end, ?TESTS).
+
+join_test_() -&gt;
+    [?_assertEqual(&quot;g:h&quot;, join(?_TEST_BASE, &quot;g:h&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g&quot;, join(?_TEST_BASE, &quot;http:g&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/d&quot;, join(?_TEST_BASE, &quot;http:&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g&quot;, join(?_TEST_BASE, &quot;g&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g&quot;, join(?_TEST_BASE, &quot;./g&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g/&quot;, join(?_TEST_BASE, &quot;g/&quot;)),
+     ?_assertEqual(&quot;http://a/g&quot;, join(?_TEST_BASE, &quot;/g&quot;)),
+     ?_assertEqual(&quot;http://g&quot;, join(?_TEST_BASE, &quot;//g&quot;)), %% Error
+     ?_assertEqual(&quot;http://a/b/c/d?y&quot;, join(?_TEST_BASE, &quot;?y&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g?y&quot;, join(?_TEST_BASE, &quot;g?y&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g?y/./x&quot;, join(?_TEST_BASE, &quot;g?y/./x&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/&quot;, join(?_TEST_BASE, &quot;.&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/&quot;, join(?_TEST_BASE, &quot;./&quot;)),
+     ?_assertEqual(&quot;http://a/b/&quot;, join(?_TEST_BASE, &quot;..&quot;)), %% Error
+     ?_assertEqual(&quot;http://a/b/&quot;, join(?_TEST_BASE, &quot;../&quot;)),
+     ?_assertEqual(&quot;http://a/b/g&quot;, join(?_TEST_BASE, &quot;../g&quot;)),
+     ?_assertEqual(&quot;http://a/&quot;, join(?_TEST_BASE, &quot;../..&quot;)),
+     ?_assertEqual(&quot;http://a/g&quot;, join(?_TEST_BASE, &quot;../../g&quot;)), %% Error
+     ?_assertEqual(&quot;http://a/../g&quot;, join(?_TEST_BASE, &quot;../../../g&quot;)), %% Error
+     ?_assertEqual(&quot;http://a/b/g&quot;, join(?_TEST_BASE, &quot;./../g&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g/&quot;, join(?_TEST_BASE, &quot;./g/.&quot;)),
+     ?_assertEqual(&quot;http://a/./g&quot;, join(?_TEST_BASE, &quot;/./g&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g/h&quot;, join(?_TEST_BASE, &quot;g/./h&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/h&quot;, join(?_TEST_BASE, &quot;g/../h&quot;)), %% Error
+     ?_assertEqual(&quot;http://a/b/c/g&quot;, join(?_TEST_BASE, &quot;http:g&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/d&quot;, join(?_TEST_BASE, &quot;http:&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/d?y&quot;, join(?_TEST_BASE, &quot;http:?y&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g?y&quot;, join(?_TEST_BASE, &quot;http:g?y&quot;)),
+     ?_assertEqual(&quot;http://a/b/c/g?y/./x&quot;, join(?_TEST_BASE, &quot;http:g?y/./x&quot;))].</diff>
      <filename>src/smak_url.erl</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>ab4d7bb3cdc81ee11677769c68b01902c3cdeeda</id>
    </parent>
  </parents>
  <author>
    <name>Hunter Morris</name>
    <email>huntermorris@gmail.com</email>
  </author>
  <url>http://github.com/skarab/smak/commit/14f1aa065bc416475cb86578ef2814d690275b4c</url>
  <id>14f1aa065bc416475cb86578ef2814d690275b4c</id>
  <committed-date>2009-03-13T08:02:37-07:00</committed-date>
  <authored-date>2009-03-13T08:02:37-07:00</authored-date>
  <message>Fixed smak_url tests

Added 'make test'</message>
  <tree>05ac72750b3f5cb79e38a82b636047f653d40d8c</tree>
  <committer>
    <name>Hunter Morris</name>
    <email>huntermorris@gmail.com</email>
  </committer>
</commit>
