def test_uncollectable(self):
        """Test uncollectable object tracking.

        This is fixed in Python 3.4 (PEP 442).
        """
        foo = Foo()
        foo.parent = foo

        enemy = Enemy()
        enemy.parent = enemy

        idfoo = id(foo)
        idenemy = id(enemy)

        del foo
        del enemy

        gb = GarbageGraph(collectable=0)

        gfoo = [x for x in gb.metadata if x.id == idfoo]
        self.assertEqual(len(gfoo), 0)
        genemy = [x for x in gb.metadata if x.id == idenemy]
        if sys.version_info < (3, 4):
            self.assertEqual(len(genemy), 1)

        self.assertEqual(gb.reduce_to_cycles(), None)
dataset/ETHPy150Open pympler/pympler/test/gui/test_garbage.py/GarbageTestCase.test_uncollectable/original