* gdb.base/list.exp (test_forward_search): Set timeout higher
authorJim Kingdon <jkingdon@engr.sgi.com>
Thu, 22 Dec 1994 00:32:15 +0000 (00:32 +0000)
committerJim Kingdon <jkingdon@engr.sgi.com>
Thu, 22 Dec 1994 00:32:15 +0000 (00:32 +0000)
when we'll be getting lots of output from gdb.

* gdb.base/a1-selftest.exp: Move code that was inside expect -re
"init_malloc" to after the expect statement.  Run it if that
regexp is taken, but also for two others which happen if source
cannot be found.

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/a1-selftest.exp

index 37bd3a47edf9751f6ee3cfe1d4d2044b891272de..94caad8ea2ae34218b17dd657c3b27ff7e13c326 100644 (file)
@@ -1,3 +1,13 @@
+Wed Dec 21 12:51:37 1994  Jim Kingdon  <kingdon@deneb.cygnus.com>
+
+       * gdb.base/list.exp (test_forward_search): Set timeout higher
+       when we'll be getting lots of output from gdb.
+
+       * gdb.base/a1-selftest.exp: Move code that was inside expect -re
+       "init_malloc" to after the expect statement.  Run it if that
+       regexp is taken, but also for two others which happen if source
+       cannot be found.
+
 Tue Dec 20 12:35:21 1994  Jim Kingdon  (kingdon@lioth.cygnus.com)
 
        * gdb.base/printcmds.exp: New test, for printing register before
index 5cf6d534919bd78e9eb40561daa897822ae494c1..6e4e2ea975ebeedf20f355309734fc2fe4babc51 100644 (file)
@@ -221,13 +221,34 @@ proc test_with_self {} {
     # now jump over a few functions
 
     set description "next over get_run_time and everything it calls"
+    set got_over_get_run_time 0
     send "next\n"
     expect {
        -re ".*init_malloc.*$prompt $" {
            pass "$description"
-           set description "next over init_malloc and everything it calls"
-           send "next\n"
-           expect {
+           set got_over_get_run_time 1
+       }
+       -re ".*No such file or directory.\r\n$prompt $" {
+           pass "$description (no source available)"
+           set got_over_get_run_time 1
+       }
+       -re ".*A file or directory .* does not exist..\r\n$prompt $" {
+           pass "$description (no source available)"
+           set got_over_get_run_time 1
+       }
+       -re ".*$prompt $" {
+           fail "$description"
+       }
+       timeout {
+           fail "$description (timeout)"
+       }
+    }
+    #    -re "if \(setmp \(to_top_level\)\).*$prompt $" { pass "first next" }
+
+    if $got_over_get_run_time then {
+       set description "next over init_malloc and everything it calls"
+       send "next\n"
+       expect {
            -re "if.*SET_TOP_LEVEL.*$prompt $" {
                pass "$description"
            }
@@ -254,24 +275,22 @@ proc test_with_self {} {
                    }
                }
              }
-          }
-       }
-       }
-       -re ".*No such file or directory.\r\n$prompt $" {
-           pass "$description (no source available)"
-       }
-       -re ".*A file or directory .* does not exist..\r\n$prompt $" {
-           pass "$description (no source available)"
-       }
-       -re ".*$prompt $" {
-           fail "$description"
-       }
-       timeout {
-           fail "$description (timeout)"
+           }
+           -re ".*No such file or directory.\r\n$prompt $" {
+               pass "$description (no source available)"
+           }
+           -re ".*A file or directory .* does not exist..\r\n$prompt $" {
+               pass "$description (no source available)"
+           }
+           -re ".*$prompt $" {
+               fail "$description"
+           }
+           default {
+               fail "$description (timeout or eof)"
+           }
        }
     }
-    #    -re "if \(setmp \(to_top_level\)\).*$prompt $" { pass "first next" }
-    
+
     # This one fails on Solaris (for some versions of gdb) because you
     # can't next over library functions
     setup_xfail "sparc-sun-solaris2" 1817
This page took 0.035956 seconds and 4 git commands to generate.