Asynchronous Unit Tests with Vitest

Asynchronous code is great. It’s the most efficient way to implement IO heavy workloads. When IO occurs, the current chain of execution is paused, allowing something else to run. There’s no multi-threading overhead. You can sustain far higher rates of effective concurrency while using only a single thread. Control is transferred at well defined points so there’s no need for critical sections and…