Fix a problem reported by Ed Maste where the test harness was failing to call bound methods as cleanup hooks