Skip to content

Conversation

@serhiy-storchaka
Copy link
Member

@serhiy-storchaka serhiy-storchaka commented Dec 28, 2025

Comment on lines +6390 to +6393
try:
self.assertFalse(rh.shouldRollover(self.next_rec()))
finally:
rh.close()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, can we use self.addCleanup(rh.close) or

with contextlib.closing(rh):
    self.assertFalse(rh.shouldRollover(self.next_rec()))

to simplify this test code?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants