Added wait for the expand all button