@@ -15,6 +15,7 @@ import {
15
15
ListCodeScanFindingsResponse ,
16
16
pollScanJobStatus ,
17
17
SecurityScanTimedOutError ,
18
+ CodeWhispererConstants ,
18
19
} from 'aws-core-vscode/codewhisperer'
19
20
import { timeoutUtils } from 'aws-core-vscode/shared'
20
21
import assert from 'assert'
@@ -303,7 +304,7 @@ describe('securityScanHandler', function () {
303
304
304
305
const pollPromise = pollScanJobStatus ( mockClient , mockJobId , CodeAnalysisScope . FILE_AUTO , mockStartTime )
305
306
306
- const expectedTimeoutMs = 60_000
307
+ const expectedTimeoutMs = CodeWhispererConstants . expressScanTimeoutMs
307
308
clock . tick ( expectedTimeoutMs + 1000 )
308
309
309
310
await assert . rejects ( ( ) => pollPromise , SecurityScanTimedOutError )
@@ -314,7 +315,7 @@ describe('securityScanHandler', function () {
314
315
315
316
const pollPromise = pollScanJobStatus ( mockClient , mockJobId , CodeAnalysisScope . PROJECT , mockStartTime )
316
317
317
- const expectedTimeoutMs = 600_000
318
+ const expectedTimeoutMs = CodeWhispererConstants . standardScanTimeoutMs
318
319
clock . tick ( expectedTimeoutMs + 1000 )
319
320
320
321
await assert . rejects ( ( ) => pollPromise , SecurityScanTimedOutError )
0 commit comments