Ejemplo n.º 1
0
    def test_deprecated_function_with_message(self):
        def test_function():
            pass

        decorated = utils.deprecated('string')(test_function)

        decorated()
        self.assertEqual(self.warn, ('function', test_function, 'string'))
Ejemplo n.º 2
0
    def test_deprecated_function_with_message(self):
        def test_function():
            pass

        decorated = utils.deprecated('string')(test_function)

        decorated()
        self.assertEqual(self.warn, ('function', test_function, 'string'))