Issue #26325: Added test.support.check_no_resource_warning() to check that
no ResourceWarning is emitted.