title: Webdriver wait for driver.current.url
body: <p>I have the following code which is working fine. But when I tried to remove the sleep from the below code I am getting the assert failure error. Can someone please suggest me how I can use <code>WebDriverWait</code> for <code>self.driver.current.url</code> i.e for validating assert.</p>
  
  <pre><code>ele = WebDriverWait(self.driver, 30).until(EC.element_to_be_clickable((By.XPATH, "//button[""@aria-label='Add Device Model']")))
  ele.click()    
  sleep(5)    
  self.assertEqual(True, ("adddevicemodel" in self.driver.current_url))
  </code></pre>