Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
ba2f8be4
Kaydet (Commit)
ba2f8be4
authored
May 12, 2013
tarafından
Georg Brandl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue #17843: Remove bz2 test data that triggers antivirus warnings.
üst
ce654f48
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
7 deletions
+12
-7
test_bz2.py
Lib/test/test_bz2.py
+6
-7
testbz2_bigmem.bz2
Lib/test/testbz2_bigmem.bz2
+0
-0
NEWS
Misc/NEWS
+6
-0
No files found.
Lib/test/test_bz2.py
Dosyayı görüntüle @
ba2f8be4
...
...
@@ -26,9 +26,6 @@ class BaseTest(unittest.TestCase):
DATA_CRLF
=
b
'BZh91AY&SY
\xae
z
\xbb
N
\x00\x01
H
\xdf\x80\x00\x12
@
\x02\xff\xf0\x01\x07
n
\x00
?
\xe7\xff\xe0
@
\x01\xbc\xc6
`
\x86
*
\x8d
=M
\xa9\x9a\x86\xd0
L@
\x0f
I
\xa6
!
\xa1\x13\xc8\x88
jdi
\x8d
@
\x03
@
\x1a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
N
\x14
$+
\x9e\xae\xd3\x80
'
EMPTY_DATA
=
b
'BZh9
\x17
rE8P
\x90\x00\x00\x00\x00
'
with
open
(
findfile
(
"testbz2_bigmem.bz2"
),
"rb"
)
as
f
:
DATA_BIGMEM
=
f
.
read
()
if
has_cmdline_bunzip2
:
def
decompress
(
self
,
data
):
pop
=
subprocess
.
Popen
(
"bunzip2"
,
shell
=
True
,
...
...
@@ -395,9 +392,10 @@ class BZ2DecompressorTest(BaseTest):
@bigmemtest
(
size
=
_4G
,
memuse
=
1.25
,
dry_run
=
False
)
def
testBigmem
(
self
,
unused_size
):
# Issue #14398: decompression fails when output data is >=2GB.
text
=
bz2
.
BZ2Decompressor
()
.
decompress
(
self
.
DATA_BIGMEM
)
compressed
=
bz2
.
compress
(
b
"a"
*
_4G
)
text
=
bz2
.
BZ2Decompressor
()
.
decompress
(
compressed
)
self
.
assertEqual
(
len
(
text
),
_4G
)
self
.
assertEqual
(
text
.
strip
(
b
"
\0
"
),
b
""
)
self
.
assertEqual
(
text
.
strip
(
b
"
a
"
),
b
""
)
class
FuncTest
(
BaseTest
):
...
...
@@ -442,9 +440,10 @@ class FuncTest(BaseTest):
@bigmemtest
(
size
=
_4G
,
memuse
=
1.25
,
dry_run
=
False
)
def
testDecompressBigmem
(
self
,
unused_size
):
# Issue #14398: decompression fails when output data is >=2GB.
text
=
bz2
.
decompress
(
self
.
DATA_BIGMEM
)
compressed
=
bz2
.
compress
(
b
"a"
*
_4G
)
text
=
bz2
.
BZ2Decompressor
()
.
decompress
(
compressed
)
self
.
assertEqual
(
len
(
text
),
_4G
)
self
.
assertEqual
(
text
.
strip
(
b
"
\0
"
),
b
""
)
self
.
assertEqual
(
text
.
strip
(
b
"
a
"
),
b
""
)
def
test_main
():
support
.
run_unittest
(
...
...
Lib/test/testbz2_bigmem.bz2
deleted
100644 → 0
Dosyayı görüntüle @
ce654f48
File deleted
Misc/NEWS
Dosyayı görüntüle @
ba2f8be4
...
...
@@ -19,6 +19,12 @@ Library
- Issue #15535: Fix namedtuple pickles which were picking up the OrderedDict
instead of just the underlying tuple.
Tests
-----
- Issue #17843: Removed bz2 test data file that was triggering false-positive
virus warnings with certain antivirus software.
What's New in Python 3.2.4?
===========================
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment