Beispiel #1
0
 def setUp(self):
     handler = (lambda x: x)
     self.capability = Capability(
         name='test',
         method='GET',
         endpoint='/test',
         version=None,
         handler=handler,
         wrapper=staticmethod(handler),
     )
Beispiel #2
0
class TestCapability(TestCase):

    def setUp(self):
        handler = (lambda x: x)
        self.capability = Capability(
            name='test',
            method='GET',
            endpoint='/test',
            version=None,
            handler=handler,
            wrapper=staticmethod(handler),
        )

    def test_001_hash(self):
        self.assertEqual(self.capability.__hash__(), hash(self.capability.name))