Lines Matching refs:Counted
1101 class Counted(object): class
1104 Counted.counter += 1
1106 Counted.counter -= 1
1110 x.a = Counted()
1111 x.b = Counted()
1112 x.c = Counted()
1113 self.assertEqual(Counted.counter, 3)
1116 self.assertEqual(Counted.counter, 0)
1120 x.a = Counted()
1121 x.z = Counted()
1122 self.assertEqual(Counted.counter, 2)
1125 self.assertEqual(Counted.counter, 0)
1129 x.a = Counted()
1130 x.z = Counted()
1131 x.e = Counted()
1132 self.assertEqual(Counted.counter, 3)
1135 self.assertEqual(Counted.counter, 0)
1141 s.a = [Counted(), s]
1142 self.assertEqual(Counted.counter, 1)
1145 self.assertEqual(Counted.counter, 0)