Proof: check the screen once more after the last Esc

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
Ludovic MarieandClaude Opus 5.5 committed 2026-10-28 19:14:26 +01:00
1 parent a683d6c60f
commit d86ecb6c4f
1 file changed
+4 -2
+4 -2
View File
@@ -46,11 +46,13 @@ class Game:
def play(self):
"""Back to the world from any screen."""
for _ in range(4):
for _ in range(6):
if self.run("status").get("screen") == "playing":
return
self.run("key", "esc", "tap")
time.sleep(0.3)
time.sleep(0.5)
if self.run("status").get("screen") == "playing":
return
raise AssertionError(f"not back in the world: {self.run('status').get('screen')}")
def labels(self):