summaryrefslogtreecommitdiff
path: root/Lib/test/test_unicodedata.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_unicodedata.py')
-rw-r--r--Lib/test/test_unicodedata.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/Lib/test/test_unicodedata.py b/Lib/test/test_unicodedata.py
index edfd860fd5..c6bbe3f5ff 100644
--- a/Lib/test/test_unicodedata.py
+++ b/Lib/test/test_unicodedata.py
@@ -11,7 +11,8 @@ from http.client import HTTPException
import sys
import unicodedata
import unittest
-from test.support import open_urlresource, requires_resource, script_helper
+from test.support import (open_urlresource, requires_resource, script_helper,
+ cpython_only)
class UnicodeMethodsTest(unittest.TestCase):
@@ -225,6 +226,11 @@ class UnicodeFunctionsTest(UnicodeDatabaseTest):
class UnicodeMiscTest(UnicodeDatabaseTest):
+ @cpython_only
+ def test_disallow_instantiation(self):
+ # Ensure that the type disallows instantiation (bpo-43916)
+ self.assertRaises(TypeError, unicodedata.UCD)
+
def test_failed_import_during_compiling(self):
# Issue 4367
# Decoding \N escapes requires the unicodedata module. If it can't be