Get an instance of the browser open to the hybrid_properties app. Args: hybrid_properties: harness for HybridProperties app Yields: WebDriver instance.
(hybrid_properties: AppHarness)
| 172 | |
| 173 | @pytest.fixture |
| 174 | def driver(hybrid_properties: AppHarness) -> Generator[WebDriver, None, None]: |
| 175 | """Get an instance of the browser open to the hybrid_properties app. |
| 176 | |
| 177 | Args: |
| 178 | hybrid_properties: harness for HybridProperties app |
| 179 | |
| 180 | Yields: |
| 181 | WebDriver instance. |
| 182 | """ |
| 183 | assert hybrid_properties.app_instance is not None, "app is not running" |
| 184 | driver = hybrid_properties.frontend() |
| 185 | try: |
| 186 | yield driver |
| 187 | finally: |
| 188 | driver.quit() |
| 189 | |
| 190 | |
| 191 | @pytest.fixture |