MCPcopy Index your code
hub / github.com/python/cpython / test_interned_string

Method test_interned_string

Lib/test/test_code.py:1201–1204  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1199
1200 @cpython_only
1201 def test_interned_string(self):
1202 co = compile('res = "str_value"', '?', 'exec')
1203 v = self.find_const(co.co_consts, 'str_value')
1204 self.assertIsInterned(v)
1205
1206 @cpython_only
1207 def test_interned_string_in_tuple(self):

Callers

nothing calls this directly

Calls 3

find_constMethod · 0.95
assertIsInternedMethod · 0.95
compileFunction · 0.50

Tested by

no test coverage detected