Fix tests for python 2.6. Refs #6857