and a unit test for the staticmethod-of-a-non-method failure just fixed
This commit is contained in:
parent
4e7785aa4f
commit
270fe88c68
|
@ -78,6 +78,12 @@ class TestDecorators(unittest.TestCase):
|
|||
self.assertEqual(C.foo(), 42)
|
||||
self.assertEqual(C().foo(), 42)
|
||||
|
||||
def test_staticmethod_function(self):
|
||||
@staticmethod
|
||||
def notamethod(x):
|
||||
return x
|
||||
self.assertRaises(TypeError, notamethod, 1)
|
||||
|
||||
def test_dotted(self):
|
||||
decorators = MiscDecorators()
|
||||
@decorators.author('Cleese')
|
||||
|
|
Loading…
Reference in New Issue