Implement Promise.sleep.

This produces a Promise that is kept after the specified time elapses.
Think of it like an asynchronous sleep, that doesn't block a thread.