add tox testing infrastructure
fix test to work on python 2.6