Fix more cases of improper test names
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.base / set-lang-auto.exp
index 5c9ab0f32d90115360d52e7431b766068ed88305..f0eb1cad139c1d54cc2a710111cc65a5c7784088 100644 (file)
@@ -1,4 +1,4 @@
-# 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.
 
@@ -46,8 +31,7 @@ gdb_test "show lang" \
 
 # 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".
@@ -56,8 +40,7 @@ gdb_test "show lang" \
          "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
This page took 0.026841 seconds and 4 git commands to generate.