Lines Matching refs:Something
42 something = sentinel.Something
98 class Something(object):
101 @patch.object(Something, 'attribute', sentinel.Patched)
103 self.assertEqual(Something.attribute, sentinel.Patched, "unpatched")
106 self.assertEqual(Something.attribute, sentinel.Original,
110 msg = "'Something' must be the actual object to be patched, not a str"
112 patch.object('Something', 'do_something')
115 class Something(object):
118 @patch.object(Something, 'attribute', None)
120 self.assertIsNone(Something.attribute, "unpatched")
123 self.assertEqual(Something.attribute, sentinel.Original,
128 class Something(object):
132 @patch.object(Something, 'attribute', sentinel.Patched)
133 @patch.object(Something, 'next_attribute', sentinel.Patched2)
135 self.assertEqual(Something.attribute, sentinel.Patched,
137 self.assertEqual(Something.next_attribute, sentinel.Patched2,
141 self.assertEqual(Something.attribute, sentinel.Original,
143 self.assertEqual(Something.next_attribute, sentinel.Original2,
169 self.assertEqual(PTModule.something, sentinel.Something,
180 self.assertEqual(PTModule.something, sentinel.Something,
188 self.assertEqual(PTModule.something, sentinel.Something,
447 class Something(object):
452 self.assertEqual(Something.attribute, sentinel.Patched,
455 self.assertEqual(Something.attribute, sentinel.Original,
458 Foo = patch.object(Something, 'attribute', sentinel.Patched)(Foo)
464 self.assertEqual(Something.attribute, sentinel.Original,
469 class Something(object):
480 self.assertEqual(PTModule.something, sentinel.Something,
488 self.assertEqual(Something.attribute, sentinel.Original,
490 self.assertEqual(PTModule.something, sentinel.Something,
495 class Something(object):
499 @patch.object(Something, 'attribute', sentinel.Patched)
500 @patch.object(Something, 'attribute', sentinel.Patched)
502 self.assertEqual(Something.attribute, sentinel.Patched, "unpatched")
506 self.assertEqual(Something.attribute, sentinel.Original,
813 class Something(object):
818 for thing in Something, SomethingElse, Something(), SomethingElse:
831 class Something(object):
836 for thing in Something, SomethingElse, Something(), SomethingElse:
837 proxy = _get_proxy(Something, get_only=False)