Definitely pass in the document. We must not use the global document or window (we can use ```window.setTimeout``` or similar of course).