fix task queue issue in tests