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
a7c9ddb5
Kaydet (Commit)
a7c9ddb5
authored
May 29, 2012
tarafından
R David Murray
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Regularize test_email/test_headerregistry's references to policy.
üst
d41595b9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
test_headerregistry.py
Lib/test/test_email/test_headerregistry.py
+6
-6
No files found.
Lib/test/test_email/test_headerregistry.py
Dosyayı görüntüle @
a7c9ddb5
...
...
@@ -650,14 +650,14 @@ class TestFolding(TestHeaderBase):
def
test_short_unstructured
(
self
):
h
=
self
.
make_header
(
'subject'
,
'this is a test'
)
self
.
assertEqual
(
h
.
fold
(
policy
=
self
.
policy
),
self
.
assertEqual
(
h
.
fold
(
policy
=
policy
.
default
),
'subject: this is a test
\n
'
)
def
test_long_unstructured
(
self
):
h
=
self
.
make_header
(
'Subject'
,
'This is a long header '
'line that will need to be folded into two lines '
'and will demonstrate basic folding'
)
self
.
assertEqual
(
h
.
fold
(
policy
=
self
.
policy
),
self
.
assertEqual
(
h
.
fold
(
policy
=
policy
.
default
),
'Subject: This is a long header line that will '
'need to be folded into two lines
\n
'
' and will demonstrate basic folding
\n
'
)
...
...
@@ -676,11 +676,11 @@ class TestFolding(TestHeaderBase):
def
test_fold_unstructured_single_word
(
self
):
h
=
self
.
make_header
(
'Subject'
,
'test'
)
self
.
assertEqual
(
h
.
fold
(
policy
=
self
.
policy
),
'Subject: test
\n
'
)
self
.
assertEqual
(
h
.
fold
(
policy
=
policy
.
default
),
'Subject: test
\n
'
)
def
test_fold_unstructured_short
(
self
):
h
=
self
.
make_header
(
'Subject'
,
'test test test'
)
self
.
assertEqual
(
h
.
fold
(
policy
=
self
.
policy
),
self
.
assertEqual
(
h
.
fold
(
policy
=
policy
.
default
),
'Subject: test test test
\n
'
)
def
test_fold_unstructured_with_overlong_word
(
self
):
...
...
@@ -721,7 +721,7 @@ class TestFolding(TestHeaderBase):
h
=
self
.
make_header
(
'To'
,
'"Theodore H. Perfect" <yes@man.com>, '
'"My address is very long because my name is long" <foo@bar.com>, '
'"Only A. Friend" <no@yes.com>'
)
self
.
assertEqual
(
h
.
fold
(
policy
=
self
.
policy
),
textwrap
.
dedent
(
"""
\
self
.
assertEqual
(
h
.
fold
(
policy
=
policy
.
default
),
textwrap
.
dedent
(
"""
\
To: "Theodore H. Perfect" <yes@man.com>,
"My address is very long because my name is long" <foo@bar.com>,
"Only A. Friend" <no@yes.com>
...
...
@@ -729,7 +729,7 @@ class TestFolding(TestHeaderBase):
def
test_fold_date_header
(
self
):
h
=
self
.
make_header
(
'Date'
,
'Sat, 2 Feb 2002 17:00:06 -0800'
)
self
.
assertEqual
(
h
.
fold
(
policy
=
self
.
policy
),
self
.
assertEqual
(
h
.
fold
(
policy
=
policy
.
default
),
'Date: Sat, 02 Feb 2002 17:00:06 -0800
\n
'
)
...
...
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