Back to index

python3.2  3.2.2
Public Member Functions | Private Member Functions
email.test.test_email_torture.TortureBase Class Reference
Inheritance diagram for email.test.test_email_torture.TortureBase:
Inheritance graph
Collaboration diagram for email.test.test_email_torture.TortureBase:
Collaboration graph

List of all members.

Public Member Functions

def ndiffAssertEqual

Private Member Functions

def _msgobj

Detailed Description

Definition at line 35 of file

Member Function Documentation

def email.test.test_email_torture.TortureBase._msgobj (   self,
) [private]

Reimplemented from email.test.test_email.TestEmailBase.

Definition at line 36 of file

00037     def _msgobj(self, filename):
00038         fp = openfile(filename)
00039         try:
00040             msg = email.message_from_file(fp)
00041         finally:
00042             fp.close()
00043         return msg

Here is the call graph for this function:

def email.test.test_email.TestEmailBase.ndiffAssertEqual (   self,
) [inherited]
Like assertEqual except use ndiff for readable output.

Definition at line 57 of file

00058     def ndiffAssertEqual(self, first, second):
00059         """Like assertEqual except use ndiff for readable output."""
00060         if first != second:
00061             sfirst = str(first)
00062             ssecond = str(second)
00063             rfirst = [repr(line) for line in sfirst.splitlines()]
00064             rsecond = [repr(line) for line in ssecond.splitlines()]
00065             diff = difflib.ndiff(rfirst, rsecond)
00066             raise self.failureException(NL + NL.join(diff))

Here is the call graph for this function:

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