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
419e8ede
Kaydet (Commit)
419e8ede
authored
Haz 10, 2016
tarafından
Berker Peksag
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Sade Fark
Issue #20900: Merge from 3.5
üst
568be632
904a2ef2
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
4 deletions
+21
-4
register.py
Lib/distutils/command/register.py
+3
-3
test_register.py
Lib/distutils/tests/test_register.py
+14
-0
test_upload.py
Lib/distutils/tests/test_upload.py
+1
-1
NEWS
Misc/NEWS
+3
-0
No files found.
Lib/distutils/command/register.py
Dosyayı görüntüle @
419e8ede
...
...
@@ -296,9 +296,9 @@ Your selection [default 1]: ''', log.INFO)
result
=
500
,
str
(
e
)
else
:
if
self
.
show_response
:
data
=
result
.
read
(
)
data
=
self
.
_read_pypi_response
(
result
)
result
=
200
,
'OK'
if
self
.
show_response
:
dashes
=
'-'
*
75
self
.
announce
(
'
%
s
%
r
%
s'
%
(
dashes
,
data
,
dashes
)
)
msg
=
'
\n
'
.
join
((
'-'
*
75
,
data
,
'-'
*
75
))
self
.
announce
(
msg
,
log
.
INFO
)
return
result
Lib/distutils/tests/test_register.py
Dosyayı görüntüle @
419e8ede
...
...
@@ -301,6 +301,20 @@ class RegisterTestCase(PyPIRCCommandTestCase):
results
=
self
.
get_logs
(
INFO
)
self
.
assertEqual
(
results
,
[
'running check'
,
'xxx'
])
def
test_show_response
(
self
):
# test that the --show-response option return a well formatted response
cmd
=
self
.
_get_cmd
()
inputs
=
Inputs
(
'1'
,
'tarek'
,
'y'
)
register_module
.
input
=
inputs
.
__call__
cmd
.
show_response
=
1
try
:
cmd
.
run
()
finally
:
del
register_module
.
input
results
=
self
.
get_logs
(
INFO
)
self
.
assertEqual
(
results
[
3
],
75
*
'-'
+
'
\n
xxx
\n
'
+
75
*
'-'
)
def
test_suite
():
return
unittest
.
makeSuite
(
RegisterTestCase
)
...
...
Lib/distutils/tests/test_upload.py
Dosyayı görüntüle @
419e8ede
...
...
@@ -140,7 +140,7 @@ class uploadTestCase(PyPIRCCommandTestCase):
# The PyPI response body was echoed
results
=
self
.
get_logs
(
INFO
)
self
.
assert
In
(
'xyzzy
\n
'
,
results
[
-
1
]
)
self
.
assert
Equal
(
results
[
-
1
],
75
*
'-'
+
'
\n
xyzzy
\n
'
+
75
*
'-'
)
def
test_upload_fails
(
self
):
self
.
next_msg
=
"Not Found"
...
...
Misc/NEWS
Dosyayı görüntüle @
419e8ede
...
...
@@ -38,6 +38,9 @@ Core and Builtins
Library
-------
- Issue #20900: distutils register command now decodes HTTP responses
correctly. Initial patch by ingrid.
- Issue #27186: Add os.PathLike support to pathlib, removing its provisional
status (part of PEP 519).
...
...
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