From eafdd4387dcd00d69626a5c8bcaa552fd312b7a2 Mon Sep 17 00:00:00 2001 From: Kirill Solomko Date: Fri, 14 Apr 2023 13:20:42 +0200 Subject: [PATCH] MT#56693 fix soundset parent_name related api-journal.t * /api/soundsets now return a field 'parent_name', which is virtual and does not exist in the db, nor is it stored in the jorunal, therefore, before testing "GET result vs a journaled sound set item", the virtual field is removed from the comparsion Change-Id: I67a5c9521aea04d40ce4014a357dff9f3d9bbd7d --- t/api-rest/api-journals.t | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/t/api-rest/api-journals.t b/t/api-rest/api-journals.t index 3f9a3c428b..2fa14244ea 100644 --- a/t/api-rest/api-journals.t +++ b/t/api-rest/api-journals.t @@ -1473,6 +1473,8 @@ sub test_soundset { $res = $ua->request($req); is($res->code, 200, _get_request_test_message("fetch POSTed test " . $test_label)); my $soundset = JSON::from_json($res->decoded_content); + # virtual and does not exist in the journal + delete $soundset->{parent_name}; _test_item_journal_link('soundsets',$soundset,$soundset->{id}); _test_journal_options_head('soundsets',$soundset->{id}); @@ -1495,6 +1497,8 @@ sub test_soundset { $res = $ua->request($req); is($res->code, 200, _get_request_test_message("fetch PUT test " . $test_label)); $soundset = JSON::from_json($res->decoded_content); + # virtual and does not exist in the journal + delete $soundset->{parent_name}; _test_item_journal_link('soundsets',$soundset,$soundset->{id}); $journal = _test_journal_top_journalitem('soundsets',$soundset->{id},$soundset,'update',$journals,$journal); @@ -1511,6 +1515,8 @@ sub test_soundset { $res = $ua->request($req); is($res->code, 200, _get_request_test_message("fetch PATCHed test " . $test_label)); $soundset = JSON::from_json($res->decoded_content); + # virtual and does not exist in the journal + delete $soundset->{parent_name}; _test_item_journal_link('soundsets',$soundset,$soundset->{id}); $journal = _test_journal_top_journalitem('soundsets',$soundset->{id},$soundset,'update',$journals,$journal);