Wait on promise resolution for tests to progress

This feels like polluting with test-specific code, hopefully there’s a better way.