use wait-until for impersonate