refactor(core): Remove all legacy auth middleware code (no-changelog) (#8755)

This commit is contained in:
कारतोफ्फेलस्क्रिप्ट™
2024-02-28 13:12:28 +01:00
committed by GitHub
parent 2e84684f04
commit 56c8791aff
37 changed files with 679 additions and 864 deletions

View File

@@ -157,18 +157,6 @@ describe('GET /login', () => {
expect(authToken).toBeUndefined();
});
test('should return cookie if UM is disabled and no cookie is already set', async () => {
await createUserShell('global:owner');
await utils.setInstanceOwnerSetUp(false);
const response = await testServer.authlessAgent.get('/login');
expect(response.statusCode).toBe(200);
const authToken = utils.getAuthToken(response);
expect(authToken).toBeDefined();
});
test('should return 401 Unauthorized if invalid cookie', async () => {
testServer.authlessAgent.jar.setCookie(`${AUTH_COOKIE_NAME}=invalid`);