diff --git a/tests/browser_test.mjs b/tests/browser_test.mjs index aedc480..98d521f 100644 --- a/tests/browser_test.mjs +++ b/tests/browser_test.mjs @@ -206,6 +206,9 @@ try{ // Entering the queue saves its final file there, whole and named after the order. const prefix='pedido-'+await kanban.eval(`board.orders.find(o=>o.id==='${oid}').number`)+'-item-1'; await waitFor(async()=>(await savedFiles()).some(n=>n.startsWith(prefix)&&!n.endsWith('.baixando')),'final file saved in the folder',45000); + // Other orders the earlier suites left in the queue may still be coming + // down: only once the round ends must no half-written file be left. + await waitFor(()=>kanban.eval('!FOLDER.busy'),'folder round finished',60000); assert.equal((await savedFiles()).some(n=>n.endsWith('.baixando')),false); } }