summaryrefslogtreecommitdiffstats
path: root/tests/integration
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2023-05-02 08:14:59 +0200
committerJoas Schilling <coding@schilljs.com>2023-05-02 17:59:32 +0200
commit0cf8800f20bc8a7b3c6368288a3d622bbf5c0d28 (patch)
treec469a5d9b81147485bb7adb3c0d99073efe17296 /tests/integration
parent76eaaee883331b57d37c9cd4a09696c94054a8e0 (diff)
fix(guests): Keep guest attendees with display name or non-default permissions
This will allow us to render the display name of guests later on. This was the idea already since we dropped the talk_guests table in nextcloud/spreed#5146 and we don't delete the attendee anymore on leaving the room since then. However, the guest clean up when fetching the participant list was still deleting the guest attendees later on when they didn't have a session. Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'tests/integration')
-rw-r--r--tests/integration/features/bootstrap/FeatureContext.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/integration/features/bootstrap/FeatureContext.php b/tests/integration/features/bootstrap/FeatureContext.php
index a98184571..6276e1bba 100644
--- a/tests/integration/features/bootstrap/FeatureContext.php
+++ b/tests/integration/features/bootstrap/FeatureContext.php
@@ -130,6 +130,10 @@ class FeatureContext implements Context, SnippetAcceptingContext {
}
}
+ if (!isset(self::$userToAttendeeId[$room][$type][$id])) {
+ throw new \Exception('Attendee id unknown, please call userLoadsAttendeeIdsInRoom with a user that has access before');
+ }
+
return self::$userToAttendeeId[$room][$type][$id];
}
@@ -1051,6 +1055,10 @@ class FeatureContext implements Context, SnippetAcceptingContext {
// in chat messages is a hashed version instead.
self::$sessionIdToUser[sha1($response['sessionId'])] = $user;
self::$userToSessionId[$user] = $response['sessionId'];
+ if (!isset(self::$userToAttendeeId[$identifier][$response['actorType']])) {
+ self::$userToAttendeeId[$identifier][$response['actorType']] = [];
+ }
+ self::$userToAttendeeId[$identifier][$response['actorType']][$response['actorId']] = $response['attendeeId'];
}
}