Add some sleep calls to an integration test

Travis-CI found a race that seems very difficult to reproduce. So I
added a couple of sleep()s.
Make asUser's temp-user deletion more robust.