-# Copyright 2008 Free Software Foundation, Inc.
+# Copyright 2008-2016 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-if $tracelevel then {
- strace $tracelevel
-}
-set prms_id 0
-set bug_id 0
+standard_testfile start.c
-set testfile start
-set srcfile ${testfile}.c
-set binfile ${objdir}/${subdir}/${testfile}
-if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
- untested "Couldn't compile test program"
+if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
return -1
}
-# Get things started.
-
-gdb_exit
-gdb_start
-gdb_reinitialize_dir $srcdir/$subdir
-gdb_load ${binfile}
-
# Do not run the inferior as the purpose of this testcase is to test
# the behavior of the "set language" command when there is no inferior.
# Now, switch the language to a specific language, instead of leaving it
# on auto.
-gdb_test "set lang ada" \
- "" \
+gdb_test_no_output "set lang ada" \
"forcing the language to ada"
# Verify that the language is now "ada".
"show lang after switching language to ada"
# Then, switch back to auto...
-gdb_test "set lang auto" \
- "" \
+gdb_test_no_output "set lang auto" \
"switching the language back to auto"
# ... And verify that the language mode is back to auto *and* that