mirror of
https://github.com/python/cpython.git
synced 2025-08-30 13:38:43 +00:00
Issue #23641: Cleaned out legacy dunder names from tests and docs.
Fixed 2 to 3 porting bug in pynche.ColorDB.
This commit is contained in:
parent
18987a11ce
commit
a60c2fe480
19 changed files with 72 additions and 124 deletions
|
@ -158,9 +158,9 @@ class PropertyTests(unittest.TestCase):
|
|||
# check that the DynamicClassAttribute's __isabstractmethod__ descriptor does the
|
||||
# right thing when presented with a value that fails truth testing:
|
||||
class NotBool(object):
|
||||
def __nonzero__(self):
|
||||
def __bool__(self):
|
||||
raise ValueError()
|
||||
__len__ = __nonzero__
|
||||
__len__ = __bool__
|
||||
with self.assertRaises(ValueError):
|
||||
class C(object):
|
||||
def foo(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue