updated so you can run integration tests
fixed up the async behavior