def test_decorate_function(self):
        """
        Test decorating a function.

        @raise AssertionError: If the test fails.
        """
        @self.time_this
        def slow_function():
            time.sleep(1)
            return 'foo'

        self.assertEquals('foo', slow_function())
        self.assertAlmostEqual(1.0, slow_function.end, delta=1.0)

        Test decorating a function.

        @raise AssertionError: If the test fails.
        
tests/structural_tests/test_decorator.py