anchor.diff:          meck:expect(timer, apply_interval, fun(_, _, _, _) ->
             {error, "should not be called"}
            end),
  -        meck:expect(autocluster_httpc, post, fun (_, _, _, _, _, _) -> {ok, []} end),
  +        meck:expect(autocluster_httpc, put, fun (_, _, _, _, _, _) -> {ok, []} end),
           os:putenv("CONSUL_SVC_TTL", ""),
           ?assertEqual(ok, autocluster_consul:register()),
           ?assert(meck:validate(timer))
  
positive.code:     fun autocluster_testing:on_finish/1,
      [
        {"default values", fun() ->
          meck:expect(autocluster_httpc, get,
            fun(Scheme, Host, Port, Path, Args) ->
              ?assertEqual("http", Scheme),
              ?assertEqual("localhost", Host),
              ?assertEqual(8500, Port),
              ?assertEqual([v1, agent, service, deregister, "rabbitmq"], Path),
              ?assertEqual([], Args),
              {ok, []}
            end),
          ?assertEqual(ok, autocluster_consul:unregister()),
          ?assert(meck:validate(autocluster_httpc))
                           end},
        {"without token", fun() ->
          meck:expect(autocluster_httpc, get,
            fun(Scheme, Host, Port, Path, Args) ->
              ?assertEqual("https", Scheme),
              ?assertEqual("consul.service.consul", Host),
              ?assertEqual(8501, Port),
              ?assertEqual([v1, agent, service, deregister,"rabbit:10.0.0.1"], Path),
              ?assertEqual([], Args),
              {ok, []}
            end),
          os:putenv("CONSUL_SCHEME", "https"),
  
negative.code:         fun() ->
            meck:expect(autocluster_util, node_hostname, fun(true) -> "bob.consul.node";
                                                            (false) -> "bob" end),
            meck:expect(autocluster_httpc, put,
              fun(Scheme, Host, Port, Path, Args, Body) ->
                ?assertEqual("http", Scheme),
                ?assertEqual("consul.service.consul", Host),
  