bpo-39489: Remove COUNT_ALLOCS special build (GH-18259) · python/cpython@c6e5c11 (original) (raw)

`@@ -2,7 +2,7 @@

`

2

2

`import unittest.mock

`

3

3

`from test.support import (verbose, refcount_test, run_unittest,

`

4

4

`cpython_only, start_threads,

`

5

``

`-

temp_dir, requires_type_collecting, TESTFN, unlink,

`

``

5

`+

temp_dir, TESTFN, unlink,

`

6

6

`import_module)

`

7

7

`from test.support.script_helper import assert_python_ok, make_script

`

8

8

``

`@@ -131,7 +131,6 @@ class A:

`

131

131

`del a

`

132

132

`self.assertNotEqual(gc.collect(), 0)

`

133

133

``

134

``

`-

@requires_type_collecting

`

135

134

`def test_newinstance(self):

`

136

135

`class A(object):

`

137

136

`pass

`

`@@ -709,7 +708,6 @@ def run_command(code):

`

709

708

`stderr = run_command(code % "gc.DEBUG_SAVEALL")

`

710

709

`self.assertNotIn(b"uncollectable objects at shutdown", stderr)

`

711

710

``

712

``

`-

@requires_type_collecting

`

713

711

`def test_gc_main_module_at_shutdown(self):

`

714

712

`# Create a reference cycle through the main module and check

`

715

713

`# it gets collected at interpreter shutdown.

`

`@@ -723,7 +721,6 @@ def del(self):

`

723

721

`rc, out, err = assert_python_ok('-c', code)

`

724

722

`self.assertEqual(out.strip(), b'del called')

`

725

723

``

726

``

`-

@requires_type_collecting

`

727

724

`def test_gc_ordinary_module_at_shutdown(self):

`

728

725

`# Same as above, but with a non-main module.

`

729

726

`with temp_dir() as script_dir:

`

`@@ -743,7 +740,6 @@ def del(self):

`

743

740

`rc, out, err = assert_python_ok('-c', code)

`

744

741

`self.assertEqual(out.strip(), b'del called')

`

745

742

``

746

``

`-

@requires_type_collecting

`

747

743

`def test_global_del_SystemExit(self):

`

748

744

`code = """if 1:

`

749

745

` class ClassWithDel:

`