Replace time.sleep by gevent.sleep in auto discovery test to avoid blocking the main thread