summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2023-02-21 13:10:16 +0100
committerJoas Schilling <coding@schilljs.com>2023-02-21 13:10:16 +0100
commit45f694dbc65e8bca504b7dc737b9ea2012a85cc9 (patch)
tree1498fa804f6a03387af1ab93ce2e88ed013d6954 /tests
parent62fd18d5002a75ee9bd7abbe9eff140c71656891 (diff)
Fix integration test
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/integration/features/bootstrap/FeatureContext.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/integration/features/bootstrap/FeatureContext.php b/tests/integration/features/bootstrap/FeatureContext.php
index 9cf5b0862..eb7b1d31b 100644
--- a/tests/integration/features/bootstrap/FeatureContext.php
+++ b/tests/integration/features/bootstrap/FeatureContext.php
@@ -2752,7 +2752,10 @@ class FeatureContext implements Context, SnippetAcceptingContext {
}
}
if (isset($expectedNotification['subject'])) {
- $data['subject'] = str_replace($notification['object_id'], '{{TOKEN}}', (string) $notification['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['object_type'])) {
$data['object_type'] = (string) $notification['object_type'];