updated for async testing