diff options
| author | Serhiy Storchaka <storchaka@gmail.com> | 2017-11-01 20:48:49 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-11-01 20:48:49 +0200 |
| commit | 4f469c096628af730b17798d0ebfd8925bfde836 (patch) | |
| tree | a161dd6075c64a45b7f16713a48df39d3c618b76 /Lib/test/test_curses.py | |
| parent | 7e68790f3db75a893d5dd336e6201a63bc70212b (diff) | |
| download | cpython-git-4f469c096628af730b17798d0ebfd8925bfde836.tar.gz | |
bpo-27666: Fixed stack corruption in curses.box() and curses.ungetmouse(). (#4220)
Diffstat (limited to 'Lib/test/test_curses.py')
| -rw-r--r-- | Lib/test/test_curses.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/Lib/test/test_curses.py b/Lib/test/test_curses.py index 8bb6630284..17b3af47c3 100644 --- a/Lib/test/test_curses.py +++ b/Lib/test/test_curses.py @@ -92,7 +92,7 @@ class TestCurses(unittest.TestCase): with self.subTest(meth=meth.__qualname__, args=args): meth(*args) - for meth in [stdscr.box, stdscr.clear, stdscr.clrtobot, + for meth in [stdscr.clear, stdscr.clrtobot, stdscr.clrtoeol, stdscr.cursyncup, stdscr.delch, stdscr.deleteln, stdscr.erase, stdscr.getbegyx, stdscr.getbkgd, stdscr.getkey, stdscr.getmaxyx, @@ -126,6 +126,13 @@ class TestCurses(unittest.TestCase): win.border(65, 66, 67, 68, 69, [], 71, 72) + win.box(65, 67) + win.box('!', '_') + win.box(b':', b'~') + self.assertRaises(TypeError, win.box, 65, 66, 67) + self.assertRaises(TypeError, win.box, 65) + win.box() + stdscr.clearok(1) win4 = stdscr.derwin(2,2) |
