We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cc39b19 commit f7264ddCopy full SHA for f7264dd
Lib/test/test_string/test_templatelib.py
@@ -18,6 +18,13 @@ def test_common(self):
18
self.assertEqual(type(i).__qualname__, 'Interpolation')
19
self.assertEqual(type(i).__module__, 'string.templatelib')
20
21
+ def test_final_types(self):
22
+ with self.assertRaisesRegex(TypeError, 'is not an acceptable base type'):
23
+ class Sub(Template): ...
24
+
25
26
+ class Sub(Interpolation): ...
27
28
def test_basic_creation(self):
29
# Simple t-string creation
30
t = t'Hello, world'
0 commit comments