def get_test_ids(self, test_id_file):
        """Returns a mapping of test to id if one exists, else an empty dictionary."""
        try:
            with open(test_id_file, 'rb') as fh:
                try:
                    from cPickle import load
                except ImportError:
                    from pickle import load
                data = load(fh)

            return dict((address, _id) for _id, address in data["ids"].items())
        except (IOError, ValueError):
            return {}
def get_test_ids ( self , test_id_file ) : try : with open ( test_id_file , 'rb' ) as fh : try : from cPickle import load except ImportError : from pickle import load data = load ( fh ) return dict ( ( address , _id ) for _id , address in data [ "ids" ] . items ( ) ) except ( IOError , ValueError ) : return { }
Returns a mapping of test to id if one exists, else an empty dictionary.