Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Lib/test/test_curses.py
Original file line number Diff line number Diff line change
Expand Up @@ -1364,6 +1364,7 @@ def test_putwin(self):
self.assertEqual(win.getmaxyx(), (5, 12))
self.assertEqual(win.instr(2, 0), b' Lorem ipsum')

@requires_curses_func('scr_dump')
def test_scr_dump(self):
# Test scr_dump(), scr_restore(), scr_init() and scr_set().
# scr_dump() writes the virtual screen to a named file; the other three
Expand Down Expand Up @@ -1722,6 +1723,9 @@ def test_state_getters(self):
('notimeout', 'is_notimeout'),
('scrollok', 'is_scrollok'),
]:
# is_keypad()/is_leaveok() are not available in every curses build.
if not hasattr(stdscr, getter):
continue
getattr(stdscr, setter)(True)
self.assertIs(getattr(stdscr, getter)(), True)
getattr(stdscr, setter)(False)
Expand Down
Loading