Skip to content

Commit

Permalink
Clarify test_flags in normal builds
Browse files Browse the repository at this point in the history
  • Loading branch information
swtaarrs committed Mar 11, 2024
1 parent 16fbd44 commit 8d39bbc
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions Lib/test/_test_embed_set_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,8 +217,13 @@ def test_flags(self):
self.assertEqual(sys.flags.gil, None)
self.set_config(enable_gil=0)
self.assertEqual(sys.flags.gil, 0)
self.set_config(enable_gil=1)
self.assertEqual(sys.flags.gil, 1)
self.set_config(enable_gil=1)
self.assertEqual(sys.flags.gil, 1)
else:
# Builds without Py_GIL_DISABLED don't have
# PyConfig.enable_gil. sys.flags.gil is always defined to 1, for
# consistency.
self.assertEqual(sys.flags.gil, 1)

def test_options(self):
self.check(warnoptions=[])
Expand Down

0 comments on commit 8d39bbc

Please sign in to comment.