Skip to content

Commit dbe737b

Browse files
committed
move workerStake compute out of the loop
1 parent 3079c74 commit dbe737b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

test/000_fullchain.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -223,11 +223,11 @@ describe('Integration tests', function () {
223223
const accounts = [requester, scheduler, appProvider, datasetProvider, ...workers];
224224
const accountsInitialFrozens = await getInitialFrozens(accounts);
225225
// Finalize each task and check balance changes.
226+
const workerStakePerTask = await iexecPoco
227+
.viewDeal(dealId)
228+
.then((deal) => deal.workerStake.toNumber());
226229
for (let taskIndex = 0; taskIndex < volume; taskIndex++) {
227230
const taskId = await iexecWrapper.initializeTask(dealId, taskIndex);
228-
const workerStakePerTask = await iexecPoco
229-
.viewDeal(dealId)
230-
.then((deal) => deal.workerStake.toNumber());
231231
for (const worker of workers) {
232232
await iexecWrapper.contributeToTask(
233233
dealId,

0 commit comments

Comments
 (0)