Cleanups for import unittest/unittest2

This change was made mechanically using sed, except for some manual edits in
test_build_graph.py and test_thrift_util.py