import re


def endsWith(self, field, term):
    """endsWith returns true if the value of the identifier ends with
    the string argument; otherwise, it returns false.
    """
    expression = "%s$" % term
    return self.compareBase(field=field, expression=expression, func=re.match)