anchor.diff:                           write_scrubed_to_db(?TEST_DB:new(randoms:getRandomString()),
                                                Data),
       {ExpInInterval, _NotIn} = lists:partition(
  -            fun(E) -> 
  -                    case Interval of
  -                        all ->
  -                            true;
  -                        {element, Key} ->
  -                            element(1, E) == Key;
  -                        {interval, '(', L, R, ')'} ->
  -                            element(1, E) > L andalso
  -                            element(1, E) < R;
  -                        {interval, '(', L, R, ']'} ->
  -                            element(1, E) > L andalso
  -                            element(1, E) =< R;
  -                        {interval, '[', L, R, ')'} ->
  -                            element(1, E) >= L andalso
  -                            element(1, E) < R;
  -                        {interval, '[', L, R, ']'} ->
  -                            element(1, E) >= L andalso
  -                            element(1, E) =< R
  -                    end
  -            end,
  -            ScrubedData),
  -    ExpInIntervalCounted = lists:sublist(ExpInInterval, MaxNum),
  +                                fun(E) ->
  +                                        is_in(Interval, element(1, E))
  +                                end,
  +                                ScrubedData),
  +    ExpInIntervalCounted = lists:sublist(lists:keysort(1, ExpInInterval), MaxNum),
       AllFold = ?TEST_DB:foldl(DB1, fun(E, AccIn) -> [E | AccIn] end, []),
       IntervalFold = ?TEST_DB:foldl(DB1,
                                    fun(E, AccIn) -> [E | AccIn] end,
  
positive.code: %% @author Jan Fajerski <fajerski@zib.de>
  %% @doc    Unit tests for db backends that fullfill src/backend_beh.erl.
  %%         just define ?TEST_DB and include this file.
  %% @end
  %% @version $Id$
  
  -include("scalaris.hrl").
  -include("unittest.hrl").
  
  tests_avail() ->
      [tester_put,
  
negative.code:             fun(Key, DBAcc) ->
                  ?TEST_DB:delete(DBAcc, Key)
              end, DB1, ToDelete),
      ExpData = lists:filter(
                  fun(El) ->
                          not lists:any(fun(Key) ->
                                            element(1, El) ?EQ Key
                                    end, ToDelete)
                  end, ScrubedData),
      check_db(DB2, ExpData, "check_db_delete"),
      ?TEST_DB:close(DB2),
      true.
  
  