anchor.diff:          ?debugVal(OmtTrees),
   
           % Insert the OMT trees one by one
  -        % XXX vmx: Doesn't work like this atm. The seedtree_write_insert/3
  -        %     shouldn't really write the new node, so that we can insert
  -        %     more nodes.
  -        %     But what should be done in case of a split? Perhaps the
  -        %     split should be made afterwards (so seedtree_write_insert/3
  -        %     should stop before the split step.
  -%        {NewMbrs, NewPos} = lists:foldl(fun(OmtTree2, {Mbrs, Pos}) ->
  -%            ?debugVal(Pos),
  -%            % seedtree_write_insert/3 might return multiple nodes, which
  -%            % means that the node was split. 
  -%            MbrAndPos = seedtree_write_insert(Fd, Pos, OmtTree2),
  -%            ?debugVal(MbrAndPos),
  -%            lists:unzip(MbrAndPos)
  -%        end, {[], Orig}, OmtTrees),
  -        ?debugVal(OmtTree),
  -        %MbrAndPos2 = seedtree_write_insert(Fd, Orig, OmtTrees),
  -        MbrAndPos2 = seedtree_write_insert(Fd, Orig, OmtTree),
  +        MbrAndPos2 = seedtree_write_insert(Fd, Orig, OmtTrees),
           {NewMbrs, NewPos} = lists:unzip(MbrAndPos2),
           ?debugVal({NewMbrs, NewPos}),
   
  
positive.code:     {ok, Lookup1} = vtree:lookup(Fd, ResultPos1, {0,0,1001,1001}),
      ?assertEqual(45, length(Lookup1)),
  
      % Test 1.2: input tree produces splits (seedtree height=2)
      TargetTreeNodeNum2 = 64,
      TargetTreeHeight2 = log_n_ceil(?MAX_FILLED, TargetTreeNodeNum2),
      {Nodes2, Fd2, RootPos2} = create_random_nodes_and_packed_tree(
  
negative.code:     ?assertEqual(1051, length(Lookup5)).
  
  
  seedtree_write_case2_test() ->
      % Test "Case 2: input R-tree is not shorter than the level of the
      % target node" (chapter 6.2)
      % Test 2.1: input tree is too high (1 level)
      TargetTreeNodeNum = 25,
      % NOTE vmx: wonder why this tree is not really dense
      {ok, {Fd, {RootPos, TargetTreeHeight}}} = vtree_test:build_random_tree(
              "/tmp/seedtree_write.bin", TargetTreeNodeNum),
      ?debugVal(TargetTreeHeight),
      ?debugVal(RootPos),
      Nodes1 = lists:foldl(fun(I, Acc) ->
          {NodeId, {NodeMbr, NodeMeta, NodeData}} =
              vtree_test:random_node({I,27+I*329,45}),
          Node = {NodeMbr, NodeMeta, {[NodeId, <<"bulk">>], NodeData}},
          [Node|Acc]
      end, [], lists:seq(1,80)),
  
      Seedtree1 = seedtree_init(Fd, RootPos, 1),
      ?debugVal(Seedtree1),
  