def random_things(self):

        things = [1, 3.1415, QWidget(), None, ['a', 'list'],
                  {'a': 'dict'}, ('a', 'long', 'tuple')]

        for thing in things:
            with self.assertRaises(ValueError):
                _process_slots(thing)
Ejemplo n.º 2
0
 def test_slot_with_None(self):
     x = ('signalname', None)
     assert _process_slots(x) == ('signalname', None)
Ejemplo n.º 3
0
 def test_complete_slot(self):
     x = ('signalname', min)
     assert _process_slots(x) == ('signalname', min)
Ejemplo n.º 4
0
 def test_callable(self):
     x = min
     assert _process_slots(x) == ('default', min)
Ejemplo n.º 5
0
 def test_specials(self):
     for x in _specials:
         assert _process_slots(x) is x