anchor.diff:  
   %% Utils
   delete_all(Table) ->
  -  Pluralized =
  -    erlang:list_to_atom(lists:append([erlang:atom_to_list(Table), "s"])),
  -  lists:map(fun(O) ->
  -                Pluralized:delete(O)
  -            end, Pluralized:all()).
  +  clear_table(Table).
  +
  +clear_table(Table) ->
  +  beehive_db_srv:delete_all(Table),
  +  ok.
   
   response_json(Response) ->
     Json = lists:last(Response),
  
positive.code:   [Headers|Body] = string:tokens(Acc, "\r\n"),
    {ok, Headers, Body}.
  
  teardown() ->
    application:set_env(beehive, beehive_home, "/tmp/beehive/test"),
    beehive:stop(),
    ok.
  
  clear_table(Table) ->
    beehive_db_srv:delete_all(Table),
    ok.
  
  start(Count)      -> start(Count, example_cluster_srv, 0, []).
  start(Count, Mod) -> start(Count, Mod, 0, []).
  start(Count, _Mod, Count, Acc) -> {ok, Acc};
  start(Count, Mod, CurrentCount, Acc) ->
    Name = erlang:list_to_atom(lists:flatten(["node", erlang:integer_to_list(CurrentCount)])),
    Seed = case erlang:length(Acc) of
             0 -> undefined;
             _ -> whereis(erlang:hd(Acc))
  
negative.code:   setup([]).
  
  setup(Proplist) when is_list(Proplist) ->
    %% only run this setup if we don't have apps loaded
    case application:get_application(sasl) of
      undefined ->
        Dir = filename:dirname(filename:dirname(code:which(?MODULE))),
        ConfigFile = filename:join([Dir, "test", "fixtures", "beehive.cfg"]),
  
        application:set_env(beehive, node_type,
                            proplists:get_value(node_type, Proplist, test_type)),
        application:set_env(beehive, config_file,
                            proplists:get_value(config_file, Proplist, ConfigFile)),
        application:set_env(beehive, beehive_home,
                            proplists:get_value(beehive_home, Proplist,
                                                "/tmp/beehive/test")),
        application:set_env(beehive, database_dir,
                            proplists:get_value(database_dir, Proplist,
                                                "/tmp/beehive/test/test_db")),
        GlitterConfig = filename:join([Dir, "test", "gitolite-admin",
                                       "conf", "gitolite.conf"]),
        application:set_env(glitter, config_file, GlitterConfig),
        application:start(sasl),
        %% We don't need any error output here.
        beehive:start([{beehive_db_srv, testing}]),
  
        inets:start();
      {ok, _} -> ok
    end;
  
  
  setup(Table) ->
    setup(),
    clear_table(Table),
    ok.
  