File tree Expand file tree Collapse file tree
checkmarx-ast-eclipse-plugin-tests/src/test/java/checkmarx/ast/eclipse/plugin/tests/ui Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -302,18 +302,23 @@ protected static void waitUntilBranchComboIsEnabled() throws TimeoutException {
302302 * Wait for connection response
303303 */
304304 protected static void waitForConnectionResponse () throws TimeoutException {
305- int retryIdx = 0 ;
306- while (!_bot .text (2 ).getText ().equals (INFO_SUCCESSFUL_CONNECTION )) {
307- if (retryIdx == 10 ) {
308- break ;
309- }
310- _bot .sleep (1000 );
311- retryIdx ++;
312- }
305+ int retryIdx = 0 ;
313306
314- if (retryIdx == 10 ) {
315- throw new TimeoutException ("Connection validation timeout after 10000ms." );
316- }
307+ while (true ) {
308+
309+ String text = _bot .text ().getText ();
310+
311+ if (text .contains (INFO_SUCCESSFUL_CONNECTION )) {
312+ return ;
313+ }
314+
315+ if (retryIdx == 10 ) {
316+ throw new TimeoutException ("Connection validation timeout after 10000ms." );
317+ }
318+
319+ _bot .sleep (1000 );
320+ retryIdx ++;
321+ }
317322 }
318323
319324 /**
You can’t perform that action at this time.
0 commit comments