diff options
Diffstat (limited to 'test/built-ins/Atomics/wake/wake-two.js')
-rw-r--r-- | test/built-ins/Atomics/wake/wake-two.js | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/test/built-ins/Atomics/wake/wake-two.js b/test/built-ins/Atomics/wake/wake-two.js index 5d436facb..bdc718e13 100644 --- a/test/built-ins/Atomics/wake/wake-two.js +++ b/test/built-ins/Atomics/wake/wake-two.js @@ -46,27 +46,27 @@ assert.sameValue(Atomics.wake(ia, 0, WAKECOUNT), WAKECOUNT); // Collect and check results var rs = []; -for ( var i=0; i < NUMAGENT; i++ ) - rs.push(getReport()); +for (var i = 0; i < NUMAGENT; i++) + rs.push(getReport()); rs.sort(); -for ( var i=0; i < WAKECOUNT; i++ ) - assert.sameValue(rs[i], "ok"); -for ( var i=WAKECOUNT; i < NUMAGENT; i++ ) - assert.sameValue(rs[i], "timed-out"); +for (var i = 0; i < WAKECOUNT; i++) + assert.sameValue(rs[i], "ok"); +for (var i = WAKECOUNT; i < NUMAGENT; i++) + assert.sameValue(rs[i], "timed-out"); function getReport() { - var r; - while ((r = $262.agent.getReport()) == null) - $262.agent.sleep(100); - return r; + var r; + while ((r = $262.agent.getReport()) == null) + $262.agent.sleep(100); + return r; } function waitUntil(ia, k, value) { - var i = 0; - while (Atomics.load(ia, k) !== value && i < 15) { - $262.agent.sleep(100); - i++; - } - assert.sameValue(Atomics.load(ia, k), value, "All agents are running"); + var i = 0; + while (Atomics.load(ia, k) !== value && i < 15) { + $262.agent.sleep(100); + i++; + } + assert.sameValue(Atomics.load(ia, k), value, "All agents are running"); } |