anchor.diff:  % socket
   -define(HOST,"localhost").
   -define(PORT,8888).
  +-define(TIMEOUT,2000). % time delay in ms to let CakeDB flush
   
   -define(STREAMNAMES, ["tempfile", "file001", "anotherfile",
           "somefile", "binfile", "cakestream"]).
  
positive.code:         {call,?MODULE,request_stream_with_size,[pos_integer(),streamname()]},
  %        {call,?MODULE,append,[streamid(S),list(integer(32,255))]},
          {call,?MODULE,append,[streamid(S),"AAAAAA"]},
          {call,?MODULE,simple_query,[streamid(S),S#state.starttime,timestamp_wrapper()]},
          {call,?MODULE,all_since,[streamid(S),S#state.starttime]},
          {call,?MODULE,last_entry_at,[streamid(S),timestamp_wrapper()]}
      ]).
  
  % define when a command is valid
  precondition(_S, _Command) ->
      true.
  
  % define the state transitions triggered
  % by each command
  next_state(S,{ok,<<_,ID>>},{call,?MODULE,request_stream_with_size,[_Size,StreamName]}) ->
      case lists:keymember(StreamName,2,S#state.streams) of
          false ->
  
negative.code:         false ->
              S
      end;
  next_state(S,_V,{call,?MODULE,request_stream,[StreamName]}) ->
      case lists:keymember(StreamName,2,S#state.streams) of
          false ->
              S#state{
                  counter = S#state.counter + 1,
                  streams = [{S#state.counter +1, StreamName, []}|S#state.streams]
              };
          true ->
              S
      end;
  %% all the other commands do not change the abstract state
  next_state(S, _V, _Command) ->
      S.
  
  %% define the conditions needed to be
  %% met in order for a test to pass
  postcondition(S, {call,?MODULE,request_stream_with_size,[_Size,StreamName]}, Result) ->
      Stream = lists:keysearch(StreamName,2,S#state.streams),
      case {Stream,Result} of
  