Skip to content

Commit a1393ff

Browse files
Merge branch 'main' into gh-98278-bracket-carets
2 parents 2098702 + f4c13c8 commit a1393ff

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎Lib/test/test_capi/test_unicode.py‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1883,7 +1883,9 @@ def test_check_interned(self):
18831883

18841884
def fresh_string(text):
18851885
# Create a new string object by decoding a bytes string.
1886-
return text.encode().decode()
1886+
# Add a suffix to make sure that it's not interned, even if
1887+
# the string is interned in the PYC file (Free Threading).
1888+
return (text + ' suffix').encode().decode()
18871889

18881890
s = fresh_string('hello')
18891891
self.assertEqual(check_interned(s), SSTATE_NOT_INTERNED)

0 commit comments

Comments
 (0)