summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2015-12-19 20:49:29 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2015-12-19 20:49:29 (GMT)
commite789038e0d2740e226aa34ec36428bdab241fc71 (patch)
tree4c76a97e17fa1bc27d61ed0cccf5b872443c7b6e
parentc06a6d0958e2eb4449605069b9c10d656ab756e8 (diff)
downloadcpython-e789038e0d2740e226aa34ec36428bdab241fc71.zip
cpython-e789038e0d2740e226aa34ec36428bdab241fc71.tar.gz
cpython-e789038e0d2740e226aa34ec36428bdab241fc71.tar.bz2
Use correct PyGC_Head size in tests for issue #25421.
-rw-r--r--Lib/test/test_sys.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_sys.py b/Lib/test/test_sys.py
index e6c17a2..4afb780 100644
--- a/Lib/test/test_sys.py
+++ b/Lib/test/test_sys.py
@@ -760,7 +760,7 @@ class SizeofTest(unittest.TestCase):
def check_slots(self, obj, base, extra):
expected = sys.getsizeof(base) + struct.calcsize(extra)
if gc.is_tracked(obj) and not gc.is_tracked(base):
- expected += struct.calcsize('3P') # PyGC_Head
+ expected += self.gc_headsize
self.assertEqual(sys.getsizeof(obj), expected)
def test_slots(self):