Skip to content

Commit bb12234

Browse files
committed
Trim the test comments
1 parent 3dd9d15 commit bb12234

1 file changed

Lines changed: 4 additions & 6 deletions

File tree

Lib/test/test_tarfile.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2436,9 +2436,8 @@ def test_pax_extended_header(self):
24362436
tar.close()
24372437

24382438
def _make_malformed_gnusparse_tar(self, pax_entries, following=b""):
2439-
# Build an in-memory tar whose pax extended ('x') header carries the
2440-
# given GNU.sparse.* records, followed by a regular file member (and
2441-
# optionally a leading data block for the sparse-1.0 map).
2439+
# Build an in-memory tar: a pax ('x') header with the given
2440+
# GNU.sparse.* records, then a file member (and any `following` data).
24422441
def pax_record(key, value):
24432442
kv = key.encode() + b"=" + value.encode() + b"\n"
24442443
n = len(kv)
@@ -2472,9 +2471,8 @@ def header(name, size, typeflag):
24722471
return io.BytesIO(blocks)
24732472

24742473
def test_pax_gnusparse_bad_number(self):
2475-
# A malformed GNU sparse number in a pax extended header is reported
2476-
# through InvalidHeaderError instead of a bare ValueError, so the
2477-
# reader stops cleanly like it does for the GNU sparse 0.0 format.
2474+
# A malformed GNU sparse number surfaces as InvalidHeaderError, not a
2475+
# bare ValueError, so the reader stops (getmembers() truncates).
24782476
cases = [
24792477
[("GNU.sparse.map", "1,notanumber")], # sparse 0.1
24802478
[("GNU.sparse.size", "notanumber")],

0 commit comments

Comments
 (0)