[gdb/testsuite] Fix gdb.tui/wrap-line.exp with wrapping disabled
There are a couple of ways that readline wrapping can be disabled: - using "set horizontal-scroll-mode on" in INPUTRC, - using a TERM setting like TERM=dumb, and - building gdb with stub-termcap. Using a trigger patch in default_gdb_init that adds "set horizontal-scroll-mode on" to INPUTRC: ... - setenv INPUTRC [cached_file inputrc "set enable-bracketed-paste off"] + setenv INPUTRC [cached_file inputrc "set enable-bracketed-paste off\nset horizontal-scroll-mode on"] ... we can easily reproduce a failure in gdb.tui/wrap-line.exp mentioned in PR testsuite/31201 (which was reported for the stub-termcap case): ... WARNING: timeout in accept_gdb_output Screen Dump (size 50 columns x 24 rows, cursor at column 34, row 1): 0 Quit 1 <89012345678901234567890123456789W 2 ... 23 FAIL: gdb.tui/wrap-line.exp: width-hard-coded: cli: wrap ... Fix this by accepting the horizontal-scroll-mode style output. We do this only when in CLI mode though, when in TUI wrapping works as before because it doesn't rely on readline. Tested on x86_64-linux. Co-Authored-By:Tom de Vries <tdevries@suse.de> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31201
Loading
Please register or sign in to comment