Back to index

python3.2  3.2.2
Public Member Functions | Public Attributes | Static Public Attributes
test.test_inspect.TestDecorators Class Reference
Inheritance diagram for test.test_inspect.TestDecorators:
Inheritance graph
[legend]
Collaboration diagram for test.test_inspect.TestDecorators:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def test_wrapped_decorator
def test_replacing_decorator
def sourcerange
def assertSourceEqual

Public Attributes

 source

Static Public Attributes

 fodderModule = mod2

Detailed Description

Definition at line 318 of file test_inspect.py.


Member Function Documentation

def test.test_inspect.GetSourceBase.assertSourceEqual (   self,
  obj,
  top,
  bottom 
) [inherited]

Definition at line 211 of file test_inspect.py.

00211 
00212     def assertSourceEqual(self, obj, top, bottom):
00213         self.assertEqual(inspect.getsource(obj),
00214                          self.sourcerange(top, bottom))

Here is the call graph for this function:

Here is the caller graph for this function:

def test.test_inspect.GetSourceBase.sourcerange (   self,
  top,
  bottom 
) [inherited]

Definition at line 207 of file test_inspect.py.

00207 
00208     def sourcerange(self, top, bottom):
00209         lines = self.source.split("\n")
00210         return "\n".join(lines[top-1:bottom]) + "\n"

Here is the caller graph for this function:

Definition at line 324 of file test_inspect.py.

00324 
00325     def test_replacing_decorator(self):
00326         self.assertSourceEqual(mod2.gone, 9, 10)

Here is the call graph for this function:

Definition at line 321 of file test_inspect.py.

00321 
00322     def test_wrapped_decorator(self):
00323         self.assertSourceEqual(mod2.wrapped, 14, 17)

Here is the call graph for this function:


Member Data Documentation

Reimplemented from test.test_inspect.GetSourceBase.

Definition at line 319 of file test_inspect.py.

Definition at line 205 of file test_inspect.py.


The documentation for this class was generated from the following file: