diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2014-07-21 14:28:54 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2014-07-21 14:28:54 (GMT) |
commit | 0bffc94d571bbd794a36aafc51ec649a26fe436f (patch) | |
tree | 023458ed84863d304c544d930ea70ae587a25655 /Lib/test/test_signal.py | |
parent | 38d773bd106d644df7509634dea6ce6ff691561b (diff) | |
download | cpython-0bffc94d571bbd794a36aafc51ec649a26fe436f.zip cpython-0bffc94d571bbd794a36aafc51ec649a26fe436f.tar.gz cpython-0bffc94d571bbd794a36aafc51ec649a26fe436f.tar.bz2 |
Issue #22018: signal.set_wakeup_fd() now raises an OSError instead of a
ValueError on fstat() failure.
Diffstat (limited to 'Lib/test/test_signal.py')
-rw-r--r-- | Lib/test/test_signal.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/test/test_signal.py b/Lib/test/test_signal.py index de3b40f..e40dfb5 100644 --- a/Lib/test/test_signal.py +++ b/Lib/test/test_signal.py @@ -252,14 +252,14 @@ class WakeupFDTests(unittest.TestCase): def test_invalid_fd(self): fd = support.make_bad_fd() - self.assertRaises(ValueError, signal.set_wakeup_fd, fd) + self.assertRaises(OSError, signal.set_wakeup_fd, fd) def test_set_wakeup_fd_result(self): r1, w1 = os.pipe() - os.close(r1) + self.addCleanup(os.close, r1) self.addCleanup(os.close, w1) r2, w2 = os.pipe() - os.close(r2) + self.addCleanup(os.close, r2) self.addCleanup(os.close, w2) signal.set_wakeup_fd(w1) |