Issue 27748: Simplify test_winsound - Python tracker (original) (raw)
test_winsound is rather annoying. It currently attempts to determine whether a sound card is present, and whether particular system sounds are available. These checks are fragile at best, and I routinely see failures that shouldn't be. In particular, if I have an open RDP session to my ware-win81-release buildbot, test_winsound fails because it thinks the sounds should fail to play, but instead they succeed.
Rather than attempt to make the checks more robust, I suggest that we instead rip out the checks and simply ensure that each call that might succeed either returns normally or raises RuntimeError. After all, we can't actually test whether a sound really played or not.