adding wait_time_in_seconds param to first wait

- so that both wait_for_environments use the wait time