Raise an error if there are errors in the browser JS console.
(self)
| 41 | self.switch_to.window(self.window_handles[0]) |
| 42 | |
| 43 | def verify_js_logs(self): |
| 44 | """Raise an error if there are errors in the browser JS console.""" |
| 45 | logs = self.get_log("browser") |
| 46 | for log in logs: |
| 47 | if log["level"] == "SEVERE": |
| 48 | msg = " ".join(log["message"].split()[2:]) |
| 49 | raise RuntimeError(f'Javascript error: "{msg}".') |
| 50 | |
| 51 | def wait_until(self, css_selector, timeout=10): |
| 52 | """Wait for and return the element(s) selected by css_selector.""" |
no outgoing calls
no test coverage detected