diff options
Diffstat (limited to 'archiva-modules')
-rw-r--r-- | archiva-modules/archiva-web/archiva-webapp-test/src/test/java/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java | 28 |
1 files changed, 26 insertions, 2 deletions
diff --git a/archiva-modules/archiva-web/archiva-webapp-test/src/test/java/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java b/archiva-modules/archiva-web/archiva-webapp-test/src/test/java/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java index 7922997e5..40d3f9852 100644 --- a/archiva-modules/archiva-web/archiva-webapp-test/src/test/java/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java +++ b/archiva-modules/archiva-web/archiva-webapp-test/src/test/java/org/apache/archiva/web/test/parent/AbstractSeleniumTest.java @@ -639,6 +639,14 @@ public abstract class AbstractSeleniumTest ex = e; count--; } + try + { + Thread.currentThread().sleep(500); + } + catch ( InterruptedException e ) + { + // Ignore + } } if (ex!=null) { Assert.fail( message); @@ -671,16 +679,32 @@ public abstract class AbstractSeleniumTest Exception ex = null; while(count>0) { + if (count<attempts) { + try + { + result = conditions.apply( getWebDriver() ); + return result; + } catch (Exception e) { + // Ignore + } + } el.click(); try { result = wait.until( conditions ); - count=0; - ex = null; + return result; } catch (Exception e) { ex = e; count--; } + try + { + Thread.currentThread().sleep(500); + } + catch ( InterruptedException e ) + { + // Ignore + } } if (ex!=null) { Assert.fail( message); |