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
e7460ac3
Kaydet (Commit)
e7460ac3
authored
Nis 23, 2014
tarafından
Gregory P. Smith
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Sade Fark
fix the test on windows which has different return codes from killed
children.
üst
ede86f5b
ab2719f9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
5 deletions
+10
-5
test_subprocess.py
Lib/test/test_subprocess.py
+10
-5
No files found.
Lib/test/test_subprocess.py
Dosyayı görüntüle @
e7460ac3
...
...
@@ -1077,17 +1077,22 @@ class ProcessTestCase(BaseTestCase):
t
=
threading
.
Timer
(
0.2
,
kill_proc_timer_thread
)
t
.
start
()
if
mswindows
:
expected_errorcode
=
1
else
:
# Should be -9 because of the proc.kill() from the thread.
expected_errorcode
=
-
9
# Wait for the process to finish; the thread should kill it
# long before it finishes on its own. Supplying a timeout
# triggers a different code path for better coverage.
proc
.
wait
(
timeout
=
20
)
# Should be -9 because of the proc.kill() from the thread.
self
.
assertEqual
(
proc
.
returncode
,
-
9
,
self
.
assertEqual
(
proc
.
returncode
,
expected_errorcode
,
msg
=
"unexpected result in wait from main thread"
)
# This should be a no-op with no change in returncode.
proc
.
wait
()
self
.
assertEqual
(
proc
.
returncode
,
-
9
,
self
.
assertEqual
(
proc
.
returncode
,
expected_errorcode
,
msg
=
"unexpected result in second main wait."
)
t
.
join
()
...
...
@@ -1096,8 +1101,8 @@ class ProcessTestCase(BaseTestCase):
# be set by the wrong thread that doesn't actually have it
# leading to an incorrect value.
self
.
assertEqual
([(
'thread-start-poll-result'
,
None
),
(
'thread-after-kill-and-wait'
,
-
9
),
(
'thread-after-second-wait'
,
-
9
)],
(
'thread-after-kill-and-wait'
,
expected_errorcode
),
(
'thread-after-second-wait'
,
expected_errorcode
)],
results
)
def
test_issue8780
(
self
):
...
...
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