Back to index

python3.2  3.2.2
Public Member Functions
test.test_tarfile.MiscTest Class Reference

List of all members.

Public Member Functions

def test_char_fields
def test_number_fields

Detailed Description

Definition at line 1577 of file

Member Function Documentation

Definition at line 1579 of file

01580     def test_char_fields(self):
01581         self.assertEqual(tarfile.stn("foo", 8, "ascii", "strict"), b"foo\0\0\0\0\0")
01582         self.assertEqual(tarfile.stn("foobar", 3, "ascii", "strict"), b"foo")
01583         self.assertEqual(tarfile.nts(b"foo\0\0\0\0\0", "ascii", "strict"), "foo")
01584         self.assertEqual(tarfile.nts(b"foo\0bar\0", "ascii", "strict"), "foo")

Here is the call graph for this function:

Definition at line 1585 of file

01586     def test_number_fields(self):
01587         self.assertEqual(tarfile.itn(1), b"0000001\x00")
01588         self.assertEqual(tarfile.itn(0xffffffff), b"\x80\x00\x00\x00\xff\xff\xff\xff")

Here is the call graph for this function:

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