Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
1 /* Any copyright is dedicated to the Public Domain.
2 * http://creativecommons.org/publicdomain/zero/1.0/ */
4 "use strict";
6 let test1Complete = false;
7 let test2Complete = false;
9 function executeWithTimeout() {
10 let deferred = Promise.defer();
11 executeSoon(function() {
12 ok(true, "we get here after a timeout");
13 deferred.resolve();
14 });
15 return deferred.promise;
16 }
18 add_task(function asyncTest_no1() {
19 yield executeWithTimeout();
20 test1Complete = true;
21 });
23 add_task(function asyncTest_no2() {
24 yield executeWithTimeout();
25 test2Complete = true;
26 });
28 add_task(function() {
29 ok(test1Complete, "We have been through test 1");
30 ok(test2Complete, "We have been through test 2");
31 });