Remove cPickle import.
Fix range.
Don't attempt qt tests on python 3 :(