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
bdce938a
Kaydet (Commit)
bdce938a
authored
Ara 20, 2013
tarafından
Zachary Ware
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Update test.outstanding_bugs.py
üst
715233c3
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
72 deletions
+2
-72
outstanding_bugs.py
Lib/test/outstanding_bugs.py
+2
-72
No files found.
Lib/test/outstanding_bugs.py
Dosyayı görüntüle @
bdce938a
...
...
@@ -10,79 +10,9 @@ import unittest
from
test
import
support
#
#
One test case for outstanding bugs at the moment:
#
No test cases for outstanding bugs at the moment.
#
# test_io
import
io
class
TextIOWrapperTest
(
unittest
.
TestCase
):
def
setUp
(
self
):
self
.
testdata
=
b
"AAA
\r\n
BBB
\r
CCC
\r\n
DDD
\n
EEE
\r\n
"
self
.
normalized
=
b
"AAA
\n
BBB
\n
CCC
\n
DDD
\n
EEE
\n
"
.
decode
(
"ASCII"
)
def
tearDown
(
self
):
support
.
unlink
(
support
.
TESTFN
)
def
test_issue1395_1
(
self
):
txt
=
io
.
TextIOWrapper
(
io
.
BytesIO
(
self
.
testdata
),
encoding
=
"ASCII"
)
# read one char at a time
reads
=
""
while
True
:
c
=
txt
.
read
(
1
)
if
not
c
:
break
reads
+=
c
self
.
assertEqual
(
reads
,
self
.
normalized
)
def
test_issue1395_2
(
self
):
txt
=
io
.
TextIOWrapper
(
io
.
BytesIO
(
self
.
testdata
),
encoding
=
"ASCII"
)
txt
.
_CHUNK_SIZE
=
4
reads
=
""
while
True
:
c
=
txt
.
read
(
4
)
if
not
c
:
break
reads
+=
c
self
.
assertEqual
(
reads
,
self
.
normalized
)
def
test_issue1395_3
(
self
):
txt
=
io
.
TextIOWrapper
(
io
.
BytesIO
(
self
.
testdata
),
encoding
=
"ASCII"
)
txt
.
_CHUNK_SIZE
=
4
reads
=
txt
.
read
(
4
)
reads
+=
txt
.
read
(
4
)
reads
+=
txt
.
readline
()
reads
+=
txt
.
readline
()
reads
+=
txt
.
readline
()
self
.
assertEqual
(
reads
,
self
.
normalized
)
def
test_issue1395_4
(
self
):
txt
=
io
.
TextIOWrapper
(
io
.
BytesIO
(
self
.
testdata
),
encoding
=
"ASCII"
)
txt
.
_CHUNK_SIZE
=
4
reads
=
txt
.
read
(
4
)
reads
+=
txt
.
read
()
self
.
assertEqual
(
reads
,
self
.
normalized
)
def
test_issue1395_5
(
self
):
txt
=
io
.
TextIOWrapper
(
io
.
BytesIO
(
self
.
testdata
),
encoding
=
"ASCII"
)
txt
.
_CHUNK_SIZE
=
4
reads
=
txt
.
read
(
4
)
pos
=
txt
.
tell
()
txt
.
seek
(
0
)
txt
.
seek
(
pos
)
self
.
assertEqual
(
txt
.
read
(
4
),
"BBB
\n
"
)
def
test_main
():
support
.
run_unittest
(
TextIOWrapperTest
)
if
__name__
==
"__main__"
:
test_
main
()
unittest
.
main
()
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