test harness: Python 2.6 compat; shell syntax optimization