anchor.diff:      set_dir_rdf_metadata_test/1,
       set_shared_file_rdf_metadata_test/1,
       set_shared_dir_rdf_metadata_test/1,
  -
  -
  +    set_file_rdf_metadata_on_provider_not_supporting_space_test/1,
  +    set_dir_rdf_metadata_on_provider_not_supporting_space_test/1,
  +
  +    % Set json metadata test cases
       set_json_metadata_test/1
   ]).
   
  
positive.code:     FilePath = filename:join(["/", ?SPACE_2, ?RANDOM_FILE_NAME]),
      {ok, FileGuid} = create_file(FileType, P1, SessIdP1, FilePath),
  
      GetRdfFun = fun(Node, FileGuid) ->
          SessId = ?USER_IN_BOTH_SPACES_SESS_ID(Node, Config),
          lfm_proxy:get_metadata(Node, SessId, {guid, FileGuid}, rdf, [], false)
      end,
      RemoveRdfFun = fun(Node, FileGuid) ->
          SessId = ?USER_IN_BOTH_SPACES_SESS_ID(Node, Config),
          lfm_proxy:remove_metadata(Node, SessId, {guid, FileGuid}, rdf)
      end,
  
      {ShareId, ClientSpec, VerifyEnvFun, GetExpCallResultFun} = case TestShareMode of
          true ->
              {ok, Id} = lfm_proxy:create_share(P1, SessIdP1, {guid, FileGuid}, <<"share">>),
              {
                  Id,
                  ?CLIENT_SPEC_FOR_SHARE_SCENARIOS(Config),
                  fun(_, #api_test_ctx{node = TestNode}) ->
                      ?assertMatch({error, ?ENODATA}, GetRdfFun(TestNode, FileGuid), ?ATTEMPTS),
                      true
                  end,
                  fun(_TestCtx) -> ?ERROR_NOT_SUPPORTED end
              };
          false ->
              {
                  undefined,
                  ?CLIENT_SPEC_FOR_SPACE_2_SCENARIOS(Config),
                  fun
                      (false, #api_test_ctx{node = TestNode}) ->
                          ?assertMatch({error, ?ENODATA}, GetRdfFun(TestNode, FileGuid), ?ATTEMPTS),
                          true;
                      (true, #api_test_ctx{node = TestNode, data = #{<<"metadata">> := Metadata}}) ->
                          lists:foreach(fun(Node) ->
                              ?assertMatch({ok, Metadata}, GetRdfFun(Node, FileGuid), ?ATTEMPTS)
                          end, Providers),
  
                          case Metadata of
                              ?RDF_METADATA_1 ->
                                  % Do nothing after setting ?RDF_METADATA_1 to test
                                  % overriding it by ?RDF_METADATA_2
                                  ok;
                              ?RDF_METADATA_2 ->
                                  % Remove ?RDF_METADATA_2 to test setting ?RDF_METADATA_1 on clean state
                                  ?assertMatch(ok, RemoveRdfFun(TestNode, FileGuid)),
                                  % Wait for removal to be synced between providers.
                                  lists:foreach(fun(Node) ->
                                      ?assertMatch({error, ?ENODATA}, GetRdfFun(Node, FileGuid), ?ATTEMPTS)
                                  end, Providers)
                          end,
                          true
                  end,
                  fun(_TestCtx) -> ok end
              }
      end,
      DataSpec = #data_spec{
          required = [<<"metadata">>],
          correct_values = #{
              <<"metadata">> => [?RDF_METADATA_1, ?RDF_METADATA_2]
          }
      },
  
      % Wait for metadata sync between providers
      ?assertMatch({ok, _}, lfm_proxy:stat(P2, SessIdP2, {guid, FileGuid}), ?ATTEMPTS),
  
      set_metadata_test_base(
          <<"rdf">>,
  
negative.code: 
  
  set_file_rdf_metadata_test(Config) ->
      set_rdf_metadata_test_base(<<"file">>, Config).
  
  
  set_dir_rdf_metadata_test(Config) ->
      set_rdf_metadata_test_base(<<"dir">>, Config).
  
  
  %% @private
  set_rdf_metadata_test_base(FileType, Config) ->
      [P2, P1] = Providers = ?config(op_worker_nodes, Config),
      SessIdP1 = ?USER_IN_BOTH_SPACES_SESS_ID(P1, Config),
      SessIdP2 = ?USER_IN_BOTH_SPACES_SESS_ID(P2, Config),
  