From 4a2415b3bd302c266a64b950e492443502630c36 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Fri, 24 Feb 2023 07:04:07 +0100 Subject: feat(recording): Add a shorter subject for the call recording notification Signed-off-by: Joas Schilling --- tests/integration/features/bootstrap/FeatureContext.php | 7 +++++-- tests/integration/features/callapi/recording.feature | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) (limited to 'tests') diff --git a/tests/integration/features/bootstrap/FeatureContext.php b/tests/integration/features/bootstrap/FeatureContext.php index 91e0df3e1..602c5d1c7 100644 --- a/tests/integration/features/bootstrap/FeatureContext.php +++ b/tests/integration/features/bootstrap/FeatureContext.php @@ -2754,8 +2754,11 @@ class FeatureContext implements Context, SnippetAcceptingContext { } if (isset($expectedNotification['subject'])) { $data['subject'] = (string) $notification['subject']; - if (str_contains($expectedNotification['subject'], '{{TOKEN}}')) { - $data['subject'] = str_replace($notification['object_id'], '{{TOKEN}}', $data['subject']); + } + if (isset($expectedNotification['message'])) { + $data['message'] = (string) $notification['message']; + if (str_contains($expectedNotification['message'], '{{TOKEN}}')) { + $data['message'] = str_replace($notification['object_id'], '{{TOKEN}}', $data['message']); } } if (isset($expectedNotification['object_type'])) { diff --git a/tests/integration/features/callapi/recording.feature b/tests/integration/features/callapi/recording.feature index 1369f1e36..dd9dc3d2d 100644 --- a/tests/integration/features/callapi/recording.feature +++ b/tests/integration/features/callapi/recording.feature @@ -402,8 +402,8 @@ Feature: callapi/recording And user "participant1" joins room "room1" with 200 (v4) When user "participant1" store recording file "/img/join_call.ogg" in room "room1" with 200 (v1) Then user "participant1" has the following notifications - | app | object_type | object_id | subject | - | spreed | recording | room1 | Recording for the call in room1 was uploaded to /Talk/Recording/{{TOKEN}}/join_call.ogg. | + | app | object_type | object_id | subject | message | + | spreed | recording | room1 | Call recording now available | The recording for the call in room1 was uploaded to /Talk/Recording/{{TOKEN}}/join_call.ogg. | And user "participant1" is participant of the following unordered rooms (v4) | type | name | callRecording | | 2 | room1 | 0 | -- cgit v1.2.3