bpo-25130: Add calls of gc.collect() in tests to support PyPy (GH-28005)

36 files changed