gdb/MAINTAINERS: add Luis Machado as global maintainer
[binutils-gdb.git] / gdb / testsuite / gdb.guile / scm-error.exp
index b5a1028d38342619b07602cf51e328cdc1dc5ded..168d71d1b9e4d716b93539db9114c74f8fff7b8c 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2010-2014 Free Software Foundation, Inc.
+# Copyright (C) 2010-2023 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
@@ -19,26 +19,21 @@ set testfile "scm-error"
 
 load_lib gdb-guile.exp
 
+require allow_guile_tests
+
 # Start with a fresh gdb.
 gdb_exit
 gdb_start
 
-# Skip all tests if Guile scripting is not enabled.
-if { [skip_guile_tests] } { continue }
-
 # Test error while loading .scm.
 
-# Give the files a new name so we don't clobber the real one if
-# objfile == srcdir.
 set remote_guile_file_1 [gdb_remote_download host \
-                            ${srcdir}/${subdir}/${testfile}-1.scm \
-                            ${subdir}/t-${testfile}-1.scm]
+                            ${srcdir}/${subdir}/${testfile}-1.scm]
 set remote_guile_file_2 [gdb_remote_download host \
-                            ${srcdir}/${subdir}/${testfile}-2.scm \
-                            ${subdir}/t-${testfile}-2.scm]
+                            ${srcdir}/${subdir}/${testfile}-2.scm]
 
 gdb_test "source $remote_guile_file_1" \
-    "(ERROR: )?In procedure \[+\]: Wrong type: #f.*" \
+    "(ERROR: )?In procedure \[+\]: Wrong type.*: #f.*" \
     "error loading scm file caught"
 
 gdb_test "p 1" " = 1" "no delayed error"
@@ -95,7 +90,7 @@ gdb_test_no_output "set guile print-stack full" \
     "set print-stack to full, for backtrace test"
 
 gdb_test "guile (define x (top-func 42))" \
-    "Guile Backtrace:.*top-func 42.*middle-func 42.*bottom-func 42.*" \
+    "Guile Backtrace:.*top-func (42|_).*middle-func (42|_).*bottom-func (42|_).*" \
     "backtrace printed"
 
 # Verify gdb-specific errors are printed properly.