Back to index

python3.2  3.2.2
Public Member Functions | Private Attributes
test.test_mailbox.TestPartialFile Class Reference
Inheritance diagram for test.test_mailbox.TestPartialFile:
Inheritance graph
[legend]
Collaboration diagram for test.test_mailbox.TestPartialFile:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def setUp
def tearDown
def test_initialize
def test_read
def test_readline
def test_readlines
def test_iteration
def test_seek_and_tell
def test_close

Private Attributes

 _path
 _file

Detailed Description

Definition at line 1929 of file test_mailbox.py.


Member Function Documentation

Definition at line 1931 of file test_mailbox.py.

01931 
01932     def setUp(self):
01933         self._path = support.TESTFN
01934         self._file = open(self._path, 'wb+')

Here is the caller graph for this function:

Definition at line 1935 of file test_mailbox.py.

01935 
01936     def tearDown(self):
01937         self._file.close()
01938         self._delete_recursively(self._path)

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 1974 of file test_mailbox.py.

01974 
01975     def test_close(self):
01976         self._file.write(bytes('&foo%sbar%s^' % (os.linesep, os.linesep), 'ascii'))
01977         self._test_close(mailbox._PartialFile(self._file, 1,
01978                                               6 + 3 * len(os.linesep)))
01979 

Here is the call graph for this function:

Definition at line 1939 of file test_mailbox.py.

01939 
01940     def test_initialize(self):
01941         # Initialize and check position
01942         self._file.write(bytes('foo' + os.linesep + 'bar', 'ascii'))
01943         pos = self._file.tell()
01944         proxy = mailbox._PartialFile(self._file, 2, 5)
01945         self.assertEqual(proxy.tell(), 0)
01946         self.assertEqual(self._file.tell(), pos)

Here is the call graph for this function:

Definition at line 1963 of file test_mailbox.py.

01963 
01964     def test_iteration(self):
01965         self._file.write(bytes('____foo%sbar%sfred%sbob####' %
01966                          (os.linesep, os.linesep, os.linesep), 'ascii'))
01967         self._test_iteration(mailbox._PartialFile(self._file, 4,
01968                                                   17 + 3 * len(os.linesep)))

Here is the call graph for this function:

Definition at line 1947 of file test_mailbox.py.

01947 
01948     def test_read(self):
01949         self._file.write(bytes('***bar***', 'ascii'))
01950         self._test_read(mailbox._PartialFile(self._file, 3, 6))

Here is the call graph for this function:

Definition at line 1951 of file test_mailbox.py.

01951 
01952     def test_readline(self):
01953         self._file.write(bytes('!!!!!foo%sbar%sfred%sbob!!!!!' %
01954                          (os.linesep, os.linesep, os.linesep), 'ascii'))
01955         self._test_readline(mailbox._PartialFile(self._file, 5,
01956                                                  18 + 3 * len(os.linesep)))

Here is the call graph for this function:

Definition at line 1957 of file test_mailbox.py.

01957 
01958     def test_readlines(self):
01959         self._file.write(bytes('foo%sbar%sfred%sbob?????' %
01960                          (os.linesep, os.linesep, os.linesep), 'ascii'))
01961         self._test_readlines(mailbox._PartialFile(self._file, 0,
01962                                                   13 + 3 * len(os.linesep)))

Here is the call graph for this function:

Definition at line 1969 of file test_mailbox.py.

01969 
01970     def test_seek_and_tell(self):
01971         self._file.write(bytes('(((foo%sbar%s$$$' % (os.linesep, os.linesep), 'ascii'))
01972         self._test_seek_and_tell(mailbox._PartialFile(self._file, 3,
01973                                                       9 + 2 * len(os.linesep)))

Here is the call graph for this function:


Member Data Documentation

Definition at line 1933 of file test_mailbox.py.

Definition at line 1932 of file test_mailbox.py.


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