mirror of
https://github.com/biobulkbende/biobulkbende.org.git
synced 2025-01-13 19:46:22 +00:00
42 lines
586 B
JavaScript
42 lines
586 B
JavaScript
"use strict";
|
|
|
|
module.exports = function (t, a, d) {
|
|
var called = 0;
|
|
var fn = t(function () {
|
|
++called;
|
|
}, 200);
|
|
|
|
fn();
|
|
a(called, 1);
|
|
fn();
|
|
fn();
|
|
a(called, 1);
|
|
// Wait 120ms
|
|
setTimeout(function () {
|
|
a(called, 1);
|
|
fn();
|
|
// Wait 120ms
|
|
setTimeout(function () {
|
|
a(called, 2);
|
|
fn();
|
|
fn();
|
|
|
|
// Wait 80ms
|
|
setTimeout(function () {
|
|
a(called, 2);
|
|
|
|
// Wait 120ms
|
|
setTimeout(function () {
|
|
a(called, 3);
|
|
|
|
// Wait 400ms
|
|
setTimeout(function () {
|
|
a(called, 3);
|
|
d();
|
|
}, 400);
|
|
}, 120);
|
|
}, 80);
|
|
}, 120);
|
|
}, 120);
|
|
};
|