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
mr11.4
Kirill Solomko 3 years ago
parent 407d6f3f3b
commit eafdd4387d

@ -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);

Loading…
Cancel
Save