gdb_test "finish" "The program is not running." "finish"
#test forward-search
# The message here comes from the regexp library, not gdb, and so can
# vary on different systems.
gdb_test "forward-search" "No previous regular expression.*|There is no previous regular expression.*" "forward-search"
#test help "h" abbreviation
gdb_test "h" "List of classes of commands:.*\[\r\n\]+aliases -- Aliases of other commands.*\[\r\n\]+breakpoints -- Making program stop at certain points.*\[\r\n\]+data -- Examining data.*\[\r\n\]+files -- Specifying and examining files.*\[\r\n\]+obscure -- Obscure features.*\[\r\n\]+running -- Running the program.*\[\r\n\]+stack -- Examining the stack.*\[\r\n\]+status -- Status inquiries.*\[\r\n\]+support -- Support facilities.*\[\r\n\]+user-defined -- User-defined commands.*\[\r\n\]+Type \"help\" followed by a class name for a list of commands in that class..*\[\r\n\]+Type \"help\" followed by command name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "help \"h\" abbreviation"
#test help
gdb_test "help" "List of classes of commands:.*\[\r\n\]+aliases -- Aliases of other commands.*\[\r\n\]+breakpoints -- Making program stop at certain points.*\[\r\n\]+data -- Examining data.*\[\r\n\]+files -- Specifying and examining files.*\[\r\n\]+obscure -- Obscure features.*\[\r\n\]+running -- Running the program.*\[\r\n\]+stack -- Examining the stack.*\[\r\n\]+status -- Status inquiries.*\[\r\n\]+support -- Support facilities.*\[\r\n\]+user-defined -- User-defined commands.*\[\r\n\]+Type \"help\" followed by a class name for a list of commands in that class..*\[\r\n\]+Type \"help\" followed by command name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "help"
#test handle
gdb_test "handle" "Argument required .signal to handle.*" "handle"
#test info "i" abbreviation
gdb_test "i" "\"info\" must be followed by the name of an info command..*\[\r\n\]+List of info subcommands:.*\[\r\n\]+Type \"help info\" followed by info subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "info \"i\" abbreviation"
#test info
gdb_test "info" "\"info\" must be followed by the name of an info command..*\[\r\n\]+List of info subcommands:.*\[\r\n\]+Type \"help info\" followed by info subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "info"
gdb_test "info breakpoints" "No breakpoints or watchpoints." "info breakpoints"
#test info catch
gdb_test "info catch" "You can't do that without a process to debug." "info catch"
#test info copying
# FIXME -- doesn't work worth a shit
#send_gdb "info copying"
# -re "GNU GENERAL PUBLIC LICENSE.*#of preserving the free status of all derivatives of our free software and.*#of promoting the sharing and reuse of software generally."#
gdb_test "info copying"
# }
#
#
#test info display
gdb_test "info display" "There are no auto-display expressions now." "info display"
gdb_test "info set" "confirm: Whether to confirm potentially dangerous operations is o\[a-z\]*..*\[\r\n\]+history filename: The filename in which to record the command history is .*\[\r\n\]+listsize: Number of source lines gdb will list by default is 10.*" "info set"
gdb_test "info source" "No current source file..*" "info source"
#test info sources
gdb_test "info sources" "No symbol table is loaded. Use the \"file\" command.*" "info sources"
#test info target
gdb_test "info target" "" "info target"
#test info terminal
gdb_test "info terminal" "No saved terminal information." "info terminal"
#test info types
gdb_test "info types" "All defined types:" "info types"
#test info variables
gdb_test "info variables" "All defined variables:" "info variables"
#test info warranty
gdb_test "info warranty" "NO WARRANTY.*\[\r\n\]+ *11. *BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY.*\[\r\n\]+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN.*\[\r\n\]+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES.*\[\r\n\]+PROVIDE THE PROGRAM \"AS IS\" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED.*\[\r\n\]+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF.*\[\r\n\]+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS.*\[\r\n\]+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE.*\[\r\n\]+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,.*\[\r\n\]+REPAIR OR CORRECTION..*\[\r\n\]+ *12. *IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING.*\[\r\n\]+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR.*\[\r\n\]+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,.*\[\r\n\]+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING.*\[\r\n\]+OUT OF THE USE OR INABILITY TO USE THE PROGRAM .INCLUDING BUT NOT LIMITED.*\[\r\n\]+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY.*\[\r\n\]+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER.*\[\r\n\]+PROGRAMS., EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE.*\[\r\n\]+POSSIBILITY OF SUCH DAMAGES.*" "info warranty"
#test info watchpoints
gdb_test "info watchpoints" "No breakpoints or watchpoints." "info watchpoints"
#test inspect
gdb_test "inspect" "The history is empty." "inspect"
gdb_test "jump" "The program is not being run." "jump"
#test kill
gdb_test "kill" "The program is not being run." "kill"
#test list "l" abbreviation
gdb_test "l" "No symbol table is loaded. Use the \"file\" command.*" "list \"l\" abbreviation"
#test list
gdb_test "list" "No symbol table is loaded. Use the \"file\" command.*" "list"
#test load
# The ``takes a file name'' case is for vxgdb.
# The ``Use the "file" command'' case is for newer GDB versions which try
# to deduce the filename from the exec file.
gdb_test "load" "You can't do that when your target is `None'.*|The load command takes a file name.*|Must specify at least a file name with the load command.*|.*Use the .file. or .exec-file. command.*" "load"
gdb_test "step" "The program is not being run." "step #1"
#test search
gdb_test "search" "No previous regular expression.*|There is no previous regular expression.*" "search"
#test section
gdb_test "section" "Must specify section name and its virtual address.*" "section"
#test set annotate
gdb_test "set annotate" "Argument required .integer to set it to.*" "set annotate"
#test set args
gdb_test "set args" "" "set args"
#test set check "c" abbreviation
gdb_test "set c" "\"set check\" must be followed by the name of a check subcommand..*\[\r\n\]+List of set check subcommands:.*\[\r\n\]+set check range -- Set range checking.*\[\r\n\]+set check type -- Set type checking.*\[\r\n\]+Type \"help set check\" followed by set check subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "set check \"c\" abbreviation"
#test set check "ch" abbreviation
gdb_test "set ch" "\"set check\" must be followed by the name of a check subcommand..*\[\r\n\]+List of set check subcommands:.*\[\r\n\]+set check range -- Set range checking.*\[\r\n\]+set check type -- Set type checking.*\[\r\n\]+Type \"help set check\" followed by set check subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "set check \"ch\" abbreviation"
#test set check
gdb_test "set check" "\"set check\" must be followed by the name of a check subcommand..*\[\r\n\]+List of set check subcommands:.*\[\r\n\]+set check range -- Set range checking.*\[\r\n\]+set check type -- Set type checking.*\[\r\n\]+Type \"help set check\" followed by set check subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "set check"
#test set check range
gdb_test "set check range" "" "set check range"
#test set check type
gdb_test "set check type" "" "set check type"
#test set complaints
gdb_test "set complaints" "Argument required .integer to set it to.*" "set complaints"
#test set confirm
gdb_test "set confirm" "" "set confirm"
# Don't test set editing. What if we're talking to a gdb that
# won't do editing correctly while we're talking to it?
gdb_test "set height" "Argument required .integer to set it to.*" "set height"
#test set history expansion
gdb_test "set history expansion" "" "set history expansion"
#test set history filename
gdb_test "set history filename" "Argument required .filename to set it to.*" "set history filename"
#test set history save
gdb_test "set history save" "" "set history save"
#test set history size
gdb_test "set history size" "Argument required .integer to set it to.*" "set history size"
#test set history
gdb_test "set history" "\"set history\" must be followed by the name of a history subcommand..*\[\r\n\]+List of set history subcommands:.*\[\r\n\]+set history expansion -- Set history expansion on command input.*\[\r\n\]+set history filename -- Set the filename in which to record the command history.*\[\r\n\]+set history save -- Set saving of the history record on exit.*\[\r\n\]+set history size -- Set the size of the command history.*\[\r\n\]+Type \"help set history\" followed by set history subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "set history"
#test set language
gdb_test "set language" "The currently understood settings are:.*\[\r\n\]+local or auto *Automatic setting based on source file.*\[\r\n\]+c *Use the C language.*\[\r\n\]+c\[+\]+ *Use the C\[+\]+ language.*\[\r\n\]+modula-2 *Use the Modula-2 language.*" "set language"
#test set listsize
gdb_test "set listsize" "Argument required .integer to set it to.*" "set listsize"
#test set print "p" abbreviation
gdb_test "set p" "\"set print\" must be followed by the name of a print subcommand..*\[\r\n\]+List of set print subcommands:.*\[\r\n\]+Type \"help set print\" followed by set print subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "set print \"p\" abbreviation"
#test set print "pr" abbreviation
gdb_test "set pr" "\"set print\" must be followed by the name of a print subcommand..*\[\r\n\]+List of set print subcommands:.*\[\r\n\]+Type \"help set print\" followed by set print subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "set print \"pr\" abbreviation"
#test set print
gdb_test "set print" "\"set print\" must be followed by the name of a print subcommand..*\[\r\n\]+List of set print subcommands:.*\[\r\n\]+Type \"help set print\" followed by set print subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "set print"
gdb_test "set variable" "Argument required .expression to compute.*" "set variable"
#test set verbose
gdb_test "set verbose" "" "set verbose"
#test set width
gdb_test "set width" "Argument required .integer to set it to.*" "set width"
#test set write
# This is only supported on targets which use exec.o.
gdb_test "set write" "" "set write"
#test set
gdb_test "set" "Argument required .expression to compute.*" "set"
#test shell echo Hi dad!
gdb_test "shell echo Hi dad!" "Hi dad!" "shell echo Hi dad!"
#test show annotate
gdb_test "show annotate" "Annotation_level is 0." "show annotate"
#test show args
gdb_test "show args" "Argument list to give program being debugged when it is started is \"\"." "show args"
#test show check "c" abbreviation
gdb_test "show c" "range: *Range checking is \"auto; currently off\"..*\[\r\n\]+type: *Type checking is \"auto; currently off\".*" "show check \"c\" abbreviation"
#test show check "ch" abbreviation
gdb_test "show ch" "range: *Range checking is \"auto; currently off\"..*\[\r\n\]+type: *Type checking is \"auto; currently off\"." "show check \"ch\" abbreviation"
#test show check
gdb_test "show check" "range: *Range checking is \"auto; currently off\"..*\[\r\n\]+type: *Type checking is \"auto; currently off\"." "show check"
#test show check range
gdb_test "show check range" "Range checking is \"auto; currently off\"." "show check range"
#test show check type
gdb_test "show check type" "Type checking is \"auto; currently off\"." "show check type"
#test show commands
gdb_test "show commands" "" "show commands"
#test show complaints
gdb_test "show complaints" "Max number of complaints about incorrect symbols is 0." "show complaints"
#test show confirm
gdb_test "show confirm" "Whether to confirm potentially dangerous operations is o\[a-z\]*." "show confirm"
#test show convenience
gdb_test "show convenience" "No debugger convenience variables now defined..*\[\r\n\]+Convenience variables have names starting with \".\";.*\[\r\n\]+use \"set\" as in \"set .foo = 5\" to define them." "show convenience"
gdb_test "show editing" "Editing of command lines as they are typed is o\[a-z\]*." "show editing"
#test show height
gdb_test "show height" "Number of lines gdb thinks are in a page is.*" "show height"
#test show history expansion
gdb_test "show history expansion" "History expansion on command input is o\[a-z\]*.*" "show history expansion"
#test show history filename
gdb_test "show history filename" "The filename in which to record the command history is.*.gdb_history.*" "show history filename"
#test show history save
gdb_test "show history save" "Saving of the history record on exit is on." "show history save"
#test show history size
gdb_test "show history size" "The size of the command history is.*" "show history size"
#test show history
gdb_test "show history" "expansion: *History expansion on command input is o.*\[\r\n\]+filename: *The filename in which to record the command history is.*.gdb_history.*\[\r\n\]+save: *Saving of the history record on exit is o.*\[\r\n\]+size: * The size of the command history is.*" "show history"
#test show language
gdb_test "show language" "The current source language is \"auto; currently c\"." "show language"
#test show listsize
gdb_test "show listsize" "Number of source lines gdb will list by default is 10." "show listsize"
#test show print "p" abbreviation
gdb_test "show p" ".*" "show p"
#test show print "pr" abbreviation
gdb_test "show pr" ".*" "show pr"
#test show print
gdb_test "show print" "" "show print"
#test show paths
gdb_test "show paths" "Executable and object file path:.*" "show paths"
#test show print address
gdb_test "show print address" "Printing of addresses is on." "show print address"
#test show print array
gdb_test "show print array" "Prettyprinting of arrays is on." "show print array"
#test show print asm-demangle
gdb_test "show print asm-demangle" "Demangling of C\[+\]+ names in disassembly listings is on." "show print asm-demangle"
#test show print demangle
gdb_test "show print demangle" "Demangling of encoded C\[+\]+ names when displaying symbols is on." "show print demangle"
#test show print elements
gdb_test "show print elements" "Limit on string chars or array elements to print is 200." "show print elements"
#test show print object
gdb_test "show print object" "Printing of object's derived type based on vtable info is on." "show print object"
#test show print pretty
gdb_test "show print pretty" "Prettyprinting of structures is on." "show print pretty"
#test show print sevenbit-strings
gdb_test "show print sevenbit-strings" "Printing of 8-bit characters in strings as .nnn is on." "show print sevenbit-strings"
#test show print union
gdb_test "show print union" "Printing of unions interior to structures is on." "show print union"
#test show print vtbl
gdb_test "show print vtbl" "Printing of C\[+\]+ virtual function tables is on." "show print vtbl"
#test show prompt
# In the FAIL case, can't just look for $gdb_prompt because that will match
# the output, rather than the prompt. So look for $gdb_prompt at the start
# of a line.
gdb_test "show prompt" "Gdb's prompt is \"$gdb_prompt \".*" "show prompt"
#test show radix
gdb_test "show radix" "Input and output radices set to decimal 10, hex a, octal 12." "show radix"
#test show symbol-reloading
gdb_test "show symbol-reloading" "Dynamic symbol table reloading multiple times in one run is on." "show symbol-reloading"
#test show user
gdb_test "show user" "" "show user"
#test show values
gdb_test "show values" "" "show values"
#test show verbose
gdb_test "show verbose" "Verbose printing of informational messages is o.*|Verbosity is off.*" "show verbose"
#test show version
gdb_test "show version" "GNU gdb \[0-9\.\]*.*\[\r\n\]+Copyright \[0-9\]* Free Software Foundation, Inc.*\[\r\n\]+GDB is free software, covered by the GNU General Public License, and you are.*\[\r\n\]+welcome to change it and/or distribute copies of it under certain conditions.*\[\r\n\]+Type \"show copying\" to see the conditions.*\[\r\n\]+There is absolutely no warranty for GDB. Type \"show warranty\" for details.*\[\r\n\]+This GDB was configured as .*|GDB is free software and you are welcome to distribute copies of it.*\[\r\n\]+ under certain conditions; type \"show copying\" to see the conditions..*\[\r\n\]+There is absolutely no warranty for GDB; type \"show warranty\" for details..*\[\r\n\]+GDB.*Copyright \[0-9\]* Free Software Foundation, Inc.*" "show version"
#test show width
gdb_test "show width" "Number of characters gdb thinks are in a line is.*" "show width"
#test show write
# This is only supported on targets which use exec.o.
gdb_test "show write" "Writing into executable and core files is o.*" "show write"
#test show
gdb_test "show" "confirm: *Whether to confirm potentially dangerous operations is on..*\[\r\n\]+history filename: *The filename in which to record the command history is .*\[\r\n\]+history save: *Saving of the history record on exit is on..*\[\r\n\]+history size: *The size of the command history is.*\[\r\n\]+listsize: *Number of source lines gdb will list by default is 10.*\[\r\n\]+print elements: *Limit on string chars or array elements to print is 200..*" "show"
gdb_test "unset" "\"unset\" must be followed by the name of an unset subcommand..*\[\r\n\]+List of unset subcommands:.*\[\r\n\]+unset environment -- Cancel environment variable VAR for the program.*\[\r\n\]+Type \"help unset\" followed by unset subcommand name for full documentation..*\[\r\n\]+Command name abbreviations are allowed if unambiguous." "unset"
#test up
#test up-silently
gdb_test "up-silently" "No stack." "up-silently"
#test watch
gdb_test "watch" "Argument required .expression to compute.*" "watch"
#test whatis
gdb_test "whatis" "The history is empty." "whatis"