Python 3.8 changed the default tar file archive format:
https://docs.python.org/3.8/whatsnew/3.8.html#tarfile.
This commit teaches our tests about the new behavior.
pulkit |
hg-reviewers |
Python 3.8 changed the default tar file archive format:
https://docs.python.org/3.8/whatsnew/3.8.html#tarfile.
This commit teaches our tests about the new behavior.
Automatic diff as part of commit; lint not applicable. |
Automatic diff as part of commit; unit tests not applicable. |
200 Script output follows | 200 Script output follows | ||||
content-disposition: attachment; filename=test-archive-1701ef1f1510.tar.gz | content-disposition: attachment; filename=test-archive-1701ef1f1510.tar.gz | ||||
content-type: application/x-gzip | content-type: application/x-gzip | ||||
date: $HTTP_DATE$ | date: $HTTP_DATE$ | ||||
etag: W/"*" (glob) | etag: W/"*" (glob) | ||||
server: testing stub value | server: testing stub value | ||||
transfer-encoding: chunked | transfer-encoding: chunked | ||||
body: size=408, sha1=8fa06531bddecc365a9f5edb0f88b65974bfe505 | body: size=408, sha1=8fa06531bddecc365a9f5edb0f88b65974bfe505 (no-py38 !) | ||||
body: size=506, sha1=70926a04cb8887d0bcccf5380488100a10222def (py-38 !) | |||||
% tar.bz2 and zip disallowed should both give 403 | % tar.bz2 and zip disallowed should both give 403 | ||||
403 Archive type not allowed: bz2 | 403 Archive type not allowed: bz2 | ||||
content-type: text/html; charset=ascii | content-type: text/html; charset=ascii | ||||
date: $HTTP_DATE$ | date: $HTTP_DATE$ | ||||
etag: W/"*" (glob) | etag: W/"*" (glob) | ||||
server: testing stub value | server: testing stub value | ||||
transfer-encoding: chunked | transfer-encoding: chunked | ||||
200 Script output follows | 200 Script output follows | ||||
content-disposition: attachment; filename=test-archive-1701ef1f1510.tar.bz2 | content-disposition: attachment; filename=test-archive-1701ef1f1510.tar.bz2 | ||||
content-type: application/x-bzip2 | content-type: application/x-bzip2 | ||||
date: $HTTP_DATE$ | date: $HTTP_DATE$ | ||||
etag: W/"*" (glob) | etag: W/"*" (glob) | ||||
server: testing stub value | server: testing stub value | ||||
transfer-encoding: chunked | transfer-encoding: chunked | ||||
body: size=426, sha1=8d87f5aba6e14f1bfea6c232985982c278b2fb0b | body: size=426, sha1=8d87f5aba6e14f1bfea6c232985982c278b2fb0b (no-py38 !) | ||||
body: size=506, sha1=1bd1f8e8d3701704bd4385038bd9c09b81c77f4e (py38 !) | |||||
% zip and tar.gz disallowed should both give 403 | % zip and tar.gz disallowed should both give 403 | ||||
403 Archive type not allowed: zip | 403 Archive type not allowed: zip | ||||
content-type: text/html; charset=ascii | content-type: text/html; charset=ascii | ||||
date: $HTTP_DATE$ | date: $HTTP_DATE$ | ||||
etag: W/"*" (glob) | etag: W/"*" (glob) | ||||
server: testing stub value | server: testing stub value | ||||
transfer-encoding: chunked | transfer-encoding: chunked | ||||
200 Script output follows | 200 Script output follows | ||||
content-disposition: attachment; filename=test-archive-1701ef1f1510.tar.gz | content-disposition: attachment; filename=test-archive-1701ef1f1510.tar.gz | ||||
content-type: application/x-gzip | content-type: application/x-gzip | ||||
date: $HTTP_DATE$ | date: $HTTP_DATE$ | ||||
etag: W/"*" (glob) | etag: W/"*" (glob) | ||||
server: testing stub value | server: testing stub value | ||||
transfer-encoding: chunked | transfer-encoding: chunked | ||||
body: size=408, sha1=8fa06531bddecc365a9f5edb0f88b65974bfe505 | body: size=408, sha1=8fa06531bddecc365a9f5edb0f88b65974bfe505 (no-py38 !) | ||||
body: size=506, sha1=70926a04cb8887d0bcccf5380488100a10222def (py38 !) | |||||
% tar.bz2 and zip disallowed should both give 403 | % tar.bz2 and zip disallowed should both give 403 | ||||
403 Archive type not allowed: bz2 | 403 Archive type not allowed: bz2 | ||||
content-type: text/html; charset=ascii | content-type: text/html; charset=ascii | ||||
date: $HTTP_DATE$ | date: $HTTP_DATE$ | ||||
etag: W/"*" (glob) | etag: W/"*" (glob) | ||||
server: testing stub value | server: testing stub value | ||||
transfer-encoding: chunked | transfer-encoding: chunked | ||||
200 Script output follows | 200 Script output follows | ||||
content-disposition: attachment; filename=test-archive-1701ef1f1510.tar.bz2 | content-disposition: attachment; filename=test-archive-1701ef1f1510.tar.bz2 | ||||
content-type: application/x-bzip2 | content-type: application/x-bzip2 | ||||
date: $HTTP_DATE$ | date: $HTTP_DATE$ | ||||
etag: W/"*" (glob) | etag: W/"*" (glob) | ||||
server: testing stub value | server: testing stub value | ||||
transfer-encoding: chunked | transfer-encoding: chunked | ||||
body: size=426, sha1=8d87f5aba6e14f1bfea6c232985982c278b2fb0b | body: size=426, sha1=8d87f5aba6e14f1bfea6c232985982c278b2fb0b (no-py38 !) | ||||
body: size=506, sha1=1bd1f8e8d3701704bd4385038bd9c09b81c77f4e (py38 !) | |||||
% zip and tar.gz disallowed should both give 403 | % zip and tar.gz disallowed should both give 403 | ||||
403 Archive type not allowed: zip | 403 Archive type not allowed: zip | ||||
content-type: text/html; charset=ascii | content-type: text/html; charset=ascii | ||||
date: $HTTP_DATE$ | date: $HTTP_DATE$ | ||||
etag: W/"*" (glob) | etag: W/"*" (glob) | ||||
server: testing stub value | server: testing stub value | ||||
transfer-encoding: chunked | transfer-encoding: chunked | ||||