diff --git a/apps/user_status/tests/Integration/Service/StatusServiceIntegrationTest.php b/apps/user_status/tests/Integration/Service/StatusServiceIntegrationTest.php index d979960f7c2bd..372843db3f006 100644 --- a/apps/user_status/tests/Integration/Service/StatusServiceIntegrationTest.php +++ b/apps/user_status/tests/Integration/Service/StatusServiceIntegrationTest.php @@ -98,10 +98,15 @@ public function testCreateRestoreBackupAutomatically(): void { 'meeting', true, ); + self::assertSame( 'meeting', $this->service->findByUserId('test123')->getMessageId(), ); + self::assertSame( + IUserStatus::ONLINE, + $this->service->findByUserId('_test123')->getStatus(), + ); $this->service->revertUserStatus( 'test123', @@ -111,6 +116,12 @@ public function testCreateRestoreBackupAutomatically(): void { IUserStatus::ONLINE, $this->service->findByUserId('test123')->getStatus(), ); + + try { + $this->service->findByUserId('_test123'); + $this->fail('Expected DoesNotExistException() to be thrown when finding backup status after reverting'); + } catch (DoesNotExistException) { + } } public function testCallOverwritesMeetingStatus(): void {