File tree Expand file tree Collapse file tree 1 file changed +4
-7
lines changed
Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ type TaskResult = { success: boolean; retry: boolean }
3737type TaskPromise = Promise < TaskResult >
3838
3939const MAX_CONCURRENCY = 20
40- const TASK_TIMEOUT = 5 * 60 * 1_000
40+ const TASK_TIMEOUT = 10 * 60 * 1_000
4141const UNIT_TEST_TIMEOUT = 60 * 1_000
4242
4343const testCommands : Record < ExerciseLanguage , { commands : string [ ] ; timeout ?: number ; cwd ?: string } > = {
@@ -343,20 +343,17 @@ const runUnitTest = async ({ task }: { task: Task }) => {
343343 let passed = true
344344
345345 for ( const command of commands ) {
346- const controller = new AbortController ( )
347- const cancelSignal = controller . signal
348- const timeout = setTimeout ( ( ) => controller . abort ( ) , cmd . timeout ?? UNIT_TEST_TIMEOUT )
346+ const timeout = cmd . timeout ?? UNIT_TEST_TIMEOUT
349347
350348 try {
351- const result = await execa ( { cwd, shell : true , reject : false , cancelSignal } ) `${ command } `
352- clearTimeout ( timeout )
349+ const result = await execa ( { cwd, shell : true , reject : false , timeout } ) `${ command } `
353350
354351 if ( result . failed ) {
355352 passed = false
356353 break
357354 }
358355 } catch ( error ) {
359- console . log ( "[cli#runUnitTest] execa error = " , error )
356+ console . log ( "[cli#runUnitTest]" , error )
360357 passed = false
361358 break
362359 }
You can’t perform that action at this time.
0 commit comments