Fix tokenization of contractions

Also, improve test coverage
Use basestring instead of string_types