Skip to content

Commit

Permalink
fix(tests): Also check that the backup status works
Browse files Browse the repository at this point in the history
Signed-off-by: Joas Schilling <[email protected]>
  • Loading branch information
nickvergessen committed Sep 24, 2024
1 parent fa969b7 commit cdfa63e
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,27 @@ 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',
'meeting',
);

try {
$this->service->findByUserId('_test123');
$this->fail('Expected DoesNotExistException() to be thrown when finding backup status after reverting');
} catch (DoesNotExistException) {
}

self::assertSame(
IUserStatus::ONLINE,
$this->service->findByUserId('test123')->getStatus(),
Expand Down

0 comments on commit cdfa63e

Please sign in to comment.