Skip to content

Commit

Permalink
analyze core.loop issue with failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
rodja committed Jul 6, 2024
1 parent dd704ee commit 725965c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions nicegui/testing/selenium_screen.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,14 @@ def is_open(self) -> bool:

def stop_server(self) -> None:
"""Stop the webserver."""
assert core.loop
self.close()
self.caplog.clear()
Server.instance.should_exit = True
if self.server_thread:
self.server_thread.join()
assert core.loop
assert core.loop.is_closed()
if core.loop is not None:
assert core.loop.is_closed()

def open(self, path: str, timeout: float = 10.0) -> None:
"""Try to open the page until the server is ready or we time out.
Expand Down

0 comments on commit 725965c

Please sign in to comment.