anchor.diff:  join_space(Config, {group, GroupId}, SpaceId) ->
       try
           [Node] = ?config(gr_nodes, Config),
  -        {ok, Token} = rpc:call(Node, token_logic, create, [space_invite_group_token, {space, SpaceId}]),
  -        {ok, SpaceId} = rpc:call(Node, space_logic, join, [{group, GroupId}, Token]),
  +        {ok, SpaceId} = rpc:call(Node, erlang, apply, [fun() ->
  +            {ok, Token} = token_logic:create(space_invite_group_token, {space, SpaceId}),
  +            {ok, Macaroon} = macaroon:deserialize(Token),
  +            space_logic:join({group, GroupId}, Macaroon)
  +        end, []]),
           ok
       catch
           _:Reason ->
  
positive.code: join_space(Config, {user, UserId}, SpaceId) ->
      try
          [Node] = ?config(gr_nodes, Config),
          {ok, Token} = rpc:call(Node, token_logic, create, [space_invite_user_token, {space, SpaceId}]),
          {ok, SpaceId} = rpc:call(Node, space_logic, join, [{user, UserId}, Token]),
          ok
      catch
          _:Reason ->
  
negative.code: join_group(Config, UserId, GroupId) ->
      try
          [Node] = ?config(gr_nodes, Config),
          rpc:call(Node, erlang, apply, [fun() ->
              {ok, Token} = token_logic:create(group_invite_token, {group, GroupId}),
              {ok, Macaroon} = macaroon:deserialize(Token),
              {ok, GroupId} = group_logic:join(UserId, Macaroon)
          end, []]),
          ok
      catch
          _:Reason ->
  