Fixes to test harness