Add tests for get_all_classes, fix a tiny py3 issue