Issue #21768: fix NameError in test_pydescr. Patch by Claudiu Popa.
diff --git a/Lib/test/test_descr.py b/Lib/test/test_descr.py
index 8bb7d6a..26c273a 100644
--- a/Lib/test/test_descr.py
+++ b/Lib/test/test_descr.py
@@ -1149,7 +1149,7 @@
         except (TypeError, UnicodeEncodeError):
             pass
         else:
-            raise TestFailed("[chr(128)] slots not caught")
+            self.fail("[chr(128)] slots not caught")
 
         # Test leaks
         class Counted(object):