Ben Finney wrote: ... > def assert_compare_true(op, first, second, msg=None): > if msg is None: > msg = "%(first)r %(op)r %(second)" % vars() > if not op(first, second): > raise self.failure_exception(msg) I would rather something more like: def assert_compare_true(op, first, second, msg=None): if op(first, second): return raise self.failure_exception(msg) if msg is None: self.failure_exception("%(first)r %(op)r %(second)" % vars()) self.failure_exception("%(first)r %(op)r %(second): %(msg)" % vars()) --Scott David Daniels Scott.Daniels at Acm.Org
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4