anchor.diff:  -include_lib("eqc/include/eqc.hrl").
   -include_lib("eqc/include/eqc_statem.hrl").
   -include_lib("eunit/include/eunit.hrl").
  +
  +-define(PUTS_ACTIVE, {riak_kv, node, puts, fsm, active}).
  +-define(GETS_ACTIVE, {riak_kv, node, gets, fsm, active}).
  +-define(PUTS_ERRORS, {riak_kv, node, puts, fsm, errors}).
  +-define(GETS_ERRORS, {riak_kv, node, gets, fsm, errors}).
   
   -compile([export_all]).
   
  
positive.code:                     ok
              end,
       fun(_) ->
               [maybe_stop_and_wait(Server) || Server <- [riak_core_stat_cache, riak_kv_stat]]
       end, [
             {timeout, 120, ?_assertEqual(true, quickcheck(numtests(100, ?QC_OUT(prop()))))}
            ]}.
  
negative.code: 
  get_fsm_started() ->
      Pid = fake_fsm(),
      Original = folsom_metrics:get_metric_value(?GETS_ACTIVE),
      riak_kv_get_put_monitor:get_fsm_spawned(Pid),
      poll_stat_change(?GETS_ACTIVE, Original),
      Pid.
  
  get_fsm_noproc() ->
      Pid = fake_fsm(),
      end_and_wait(Pid, normal),
      riak_kv_get_put_monitor:get_fsm_spawned(Pid),
      Pid.
  
  get_fsm_exit_normal(get, Pid) ->
      Original = folsom_metrics:get_metric_value(?GETS_ACTIVE),
      end_and_wait(Pid, normal),
      poll_stat_change(?GETS_ACTIVE, Original),
      Pid.
  
  get_fsm_exit_shutdown(get, Pid) ->
      Original = folsom_metrics:get_metric_value(?GETS_ACTIVE),
      end_and_wait(Pid, shutdown),
      poll_stat_change(?GETS_ACTIVE, Original),
      Pid.
  
  get_fsm_exit_error(get, Pid) ->
      Original = folsom_metrics:get_metric_value(?GETS_ERRORS),
      end_and_wait(Pid, unnatural),
      poll_stat_change(?GETS_ERRORS, Original),
      Pid.
  
  put_fsm_started() ->
      Original = folsom_metrics:get_metric_value(?PUTS_ACTIVE),
      Pid = fake_fsm(),
      riak_kv_get_put_monitor:put_fsm_spawned(Pid),
      poll_stat_change(?PUTS_ACTIVE, Original),
      Pid.
  
  put_fsm_noproc() ->
      Pid = fake_fsm(),
      end_and_wait(Pid, normal),
      riak_kv_get_put_monitor:put_fsm_spawned(Pid),
      Pid.
  
  put_fsm_exit_normal(put, Pid) ->
      Original = folsom_metrics:get_metric_value(?PUTS_ACTIVE),
      end_and_wait(Pid, normal),
      poll_stat_change(?PUTS_ACTIVE, Original),
      Pid.
  
  put_fsm_exit_shutdown(put, Pid) ->
      Original = folsom_metrics:get_metric_value(?PUTS_ACTIVE),
      end_and_wait(Pid, shutdown),
      poll_stat_change(?PUTS_ACTIVE, Original),
      Pid.
  
  put_fsm_exit_error(put, Pid) ->
      Original = folsom_metrics:get_metric_value(?PUTS_ERRORS),
      end_and_wait(Pid, unnatural),
      poll_stat_change(?PUTS_ERRORS, Original),
      Pid.
  
  %% ====================================================================
  