8208471: nsk/jdb/unwatch/unwatch002/unwatch002.java fails with "Prompt is not received during 300200 milliseconds"
authorgadams
Fri, 21 Sep 2018 08:13:55 -0400
changeset 51843 16f0deae8fa6
parent 51842 b7153eff0558
child 51844 354fb27fd38a
8208471: nsk/jdb/unwatch/unwatch002/unwatch002.java fails with "Prompt is not received during 300200 milliseconds" Reviewed-by: cjplummer, amenkov
test/hotspot/jtreg/vmTestbase/nsk/jdb/unwatch/unwatch002/unwatch002.java
--- a/test/hotspot/jtreg/vmTestbase/nsk/jdb/unwatch/unwatch002/unwatch002.java	Sat Sep 22 14:12:48 2018 -0700
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jdb/unwatch/unwatch002/unwatch002.java	Fri Sep 21 08:13:55 2018 -0400
@@ -91,6 +91,7 @@
     static final String DEBUGGEE_CLASS2    = DEBUGGEE_CLASS + "$CheckedFields";
     static final String FIRST_BREAK        = DEBUGGEE_CLASS + ".main";
     static final String LAST_BREAK         = DEBUGGEE_CLASS + ".breakHere";
+    static final String expectedPrompt     = "main[1]";
 
     static String[] checkedFields  = { "FS1" };
     static String[] checkedFields2 = { "FT1", "FV1" };
@@ -113,7 +114,7 @@
 
 //        jdb.contToExit((checkedFields.length *2)  + (checkedFields2.length *2) + 2);
         for (int i = 0; i < (checkedFields.length *2 + checkedFields2.length*2 + 2); i++) {
-            reply = jdb.receiveReplyFor(JdbCommand.cont);
+            reply = jdb.receiveReplyForWithMessageWait(JdbCommand.cont, expectedPrompt);
         }
 
         unwatchFields (DEBUGGEE_CLASS, checkedFields);