Implement withTimeout(promise, ms) that races a given promise against a
timeout. If the promise resolves before ms milliseconds, return its value.
Otherwise throw/reject with 'TIMEOUT'.
solve(resolveAfter, timeoutMs) simulates this by creating a promise that
resolves with 'done' after resolveAfter ms.
Sample tests