def assertBody(self, value, msg=None):
        if isinstance(value, unicodestr):
            value = value.encode(self.encoding)
        if value != self.body:
            if msg is None:
                msg = 'expected body:\n%r\n\nactual body:\n%r' % (value, self.body)
            self._handlewebError(msg)
Calculate the effective width of the given text (ignoring ANSI escape sequences).
dataset/ETHPy150Open AppScale/appscale/AppServer/lib/cherrypy/cherrypy/test/webtest.py/WebCase.assertBody--crossover with--dataset/ETHPy150Open xolox/python-humanfriendly/humanfriendly/terminal.py/ansi_width