fixes unit testing bugs for https://github.com/nltk/nltk/issues/581
removed now unnecessary calls to sorted()
added back unittest & sorted, see comments: https://github.com/nltk/nltk/pull/583
Merge pull request #583 from jskda/pull_request.581

fixes unit testing bugs for https://github.com/nltk/nltk/issues/581