mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Issue #19595: Re-enable a long-disabled test in test_winsound
This commit is contained in:
parent
23bdd83053
commit
50a5dad608
2 changed files with 10 additions and 12 deletions
|
@ -158,18 +158,14 @@ class PlaySoundTest(unittest.TestCase):
|
|||
)
|
||||
|
||||
def test_alias_fallback(self):
|
||||
# This test can't be expected to work on all systems. The MS
|
||||
# PlaySound() docs say:
|
||||
#
|
||||
# If it cannot find the specified sound, PlaySound uses the
|
||||
# default system event sound entry instead. If the function
|
||||
# can find neither the system default entry nor the default
|
||||
# sound, it makes no sound and returns FALSE.
|
||||
#
|
||||
# It's known to return FALSE on some real systems.
|
||||
|
||||
# winsound.PlaySound('!"$%&/(#+*', winsound.SND_ALIAS)
|
||||
return
|
||||
if _have_soundcard():
|
||||
winsound.PlaySound('!"$%&/(#+*', winsound.SND_ALIAS)
|
||||
else:
|
||||
self.assertRaises(
|
||||
RuntimeError,
|
||||
winsound.PlaySound,
|
||||
'!"$%&/(#+*', winsound.SND_ALIAS
|
||||
)
|
||||
|
||||
def test_alias_nofallback(self):
|
||||
if _have_soundcard():
|
||||
|
|
|
@ -31,6 +31,8 @@ Library
|
|||
Tests
|
||||
-----
|
||||
|
||||
- Issue #19595: Re-enabled a long-disabled test in test_winsound.
|
||||
|
||||
- Issue #19588: Fixed tests in test_random that were silently skipped most
|
||||
of the time. Patch by Julian Gindi.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue