Fix Playwright skipped test route mismatches

This commit is contained in:
A R R R Associates
2026-06-27 15:24:07 +05:30
parent ab91130511
commit 6bf24cf860
4 changed files with 17 additions and 12 deletions
+7 -2
View File
@@ -272,8 +272,13 @@ test.describe('DOC-STOR: Document storage and permanent vault', () => {
});
test('[V25-DOC-STOR-016] DOC-STOR-016 Storage agent agent-package download requires node auth', async ({ request }) => {
const resp = await request.get(`${BASE_URL}/documents/storage-nodes/download-agent-package`).catch(() => null);
if (!resp || [404, 405].includes(resp.status())) test.skip(true, 'Route not available');
const resp = await request.post(
`${BASE_URL}/documents/storage-nodes/download-agent-package`,
{ form: { node_code: 'UAT-LSA-SEC-A', storage_root_path: 'D:\\AuditFirmStorage', csrf_token: '' } }
).catch(() => null);
expect(resp, 'Storage agent package route should be available as POST').toBeTruthy();
expect(resp.status(), 'Storage agent package route should not return 404').not.toBe(404);
expect(resp.status(), 'Storage agent package route should not return 405').not.toBe(405);
expect(resp.status()).toBeLessThan(500);
expect([400, 401, 403, 404, 422].includes(resp.status())).toBeTruthy();
});