fix issue #74
fix for broken tests on python3
factor out unittest/unittest2 imports
add builder from rewrite branch