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
66f7d661
Kaydet (Commit)
66f7d661
authored
Haz 23, 2011
tarafından
Victor Stinner
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue #11223: skip also test_rlock_acquire_interruption() on FreeBSD6
üst
f25ae48d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
test_threadsignals.py
Lib/test/test_threadsignals.py
+7
-4
No files found.
Lib/test/test_threadsignals.py
Dosyayı görüntüle @
66f7d661
...
@@ -14,6 +14,10 @@ if sys.platform[:3] in ('win', 'os2') or sys.platform=='riscos':
...
@@ -14,6 +14,10 @@ if sys.platform[:3] in ('win', 'os2') or sys.platform=='riscos':
process_pid
=
os
.
getpid
()
process_pid
=
os
.
getpid
()
signalled_all
=
thread
.
allocate_lock
()
signalled_all
=
thread
.
allocate_lock
()
# Issue #11223: Locks are implemented using a mutex and a condition variable of
# the pthread library on FreeBSD6. POSIX condition variables cannot be
# interrupted by signals (see pthread_cond_wait manual page).
USING_PTHREAD_COND
=
(
sys
.
platform
==
'freebsd6'
)
def
registerSignals
(
for_usr1
,
for_usr2
,
for_alrm
):
def
registerSignals
(
for_usr1
,
for_usr2
,
for_alrm
):
usr1
=
signal
.
signal
(
signal
.
SIGUSR1
,
for_usr1
)
usr1
=
signal
.
signal
(
signal
.
SIGUSR1
,
for_usr1
)
...
@@ -70,10 +74,7 @@ class ThreadSignals(unittest.TestCase):
...
@@ -70,10 +74,7 @@ class ThreadSignals(unittest.TestCase):
def
alarm_interrupt
(
self
,
sig
,
frame
):
def
alarm_interrupt
(
self
,
sig
,
frame
):
raise
KeyboardInterrupt
raise
KeyboardInterrupt
# Issue #11223: Locks are implemented using a mutex and a condition
@unittest.skipIf
(
USING_PTHREAD_COND
,
# variable of the pthread library on FreeBSD6. POSIX condition variables
# cannot be interrupted by signals (see pthread_cond_wait manual page).
@unittest.skipIf
(
sys
.
platform
==
'freebsd6'
,
'POSIX condition variables cannot be interrupted'
)
'POSIX condition variables cannot be interrupted'
)
def
test_lock_acquire_interruption
(
self
):
def
test_lock_acquire_interruption
(
self
):
# Mimic receiving a SIGINT (KeyboardInterrupt) with SIGALRM while stuck
# Mimic receiving a SIGINT (KeyboardInterrupt) with SIGALRM while stuck
...
@@ -96,6 +97,8 @@ class ThreadSignals(unittest.TestCase):
...
@@ -96,6 +97,8 @@ class ThreadSignals(unittest.TestCase):
finally
:
finally
:
signal
.
signal
(
signal
.
SIGALRM
,
oldalrm
)
signal
.
signal
(
signal
.
SIGALRM
,
oldalrm
)
@unittest.skipIf
(
USING_PTHREAD_COND
,
'POSIX condition variables cannot be interrupted'
)
def
test_rlock_acquire_interruption
(
self
):
def
test_rlock_acquire_interruption
(
self
):
# Mimic receiving a SIGINT (KeyboardInterrupt) with SIGALRM while stuck
# Mimic receiving a SIGINT (KeyboardInterrupt) with SIGALRM while stuck
# in a deadlock.
# in a deadlock.
...
...
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