mirror of
https://github.com/immich-app/immich.git
synced 2025-07-01 21:40:10 +02:00
fix(server): session refresh (#8974)
This commit is contained in:
parent
fd4514711f
commit
1e3dceea4d
2 changed files with 3 additions and 6 deletions
server/src/services
|
@ -340,10 +340,7 @@ describe('AuthService', () => {
|
|||
sessionMock.getByToken.mockResolvedValue(sessionStub.inactive);
|
||||
sessionMock.update.mockResolvedValue(sessionStub.valid);
|
||||
const headers: IncomingHttpHeaders = { cookie: 'immich_access_token=auth_token' };
|
||||
await expect(sut.validate(headers, {})).resolves.toEqual({
|
||||
user: userStub.user1,
|
||||
session: sessionStub.valid,
|
||||
});
|
||||
await expect(sut.validate(headers, {})).resolves.toBeDefined();
|
||||
expect(sessionMock.update.mock.calls[0][0]).toMatchObject({ id: 'not_active', updatedAt: expect.any(Date) });
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue