Skip to content

Commit 23c6f42

Browse files
committed
Remove container directly in run_and_wait
1 parent f47292e commit 23c6f42

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/utils/tracked_container.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ def run_and_wait(
9191
assert no_warnings == (not self.get_warnings(logs))
9292
assert no_errors == (not self.get_errors(logs))
9393
assert no_failure == (rv["StatusCode"] == 0)
94+
self.remove()
9495
return logs
9596

9697
@staticmethod
@@ -113,3 +114,4 @@ def remove(self) -> None:
113114
LOGGER.info(f"Removing container {self.container.name} ...")
114115
self.container.remove(force=True)
115116
LOGGER.info(f"Container {self.container.name} removed")
117+
self.container = None

0 commit comments

Comments
 (0)