Fix #10591. Fix test_os for refleak runs. Split a common setUp/tearDown into the appropriate parts.
Fix #10591. Fix test_os for refleak runs.
Split a common setUp/tearDown into the appropriate parts.

sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator