mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-11-12 21:55:37 +00:00
bug 4942: mark updating of local server settings to allow selenium test
to await changes
This commit is contained in:
1 parent
bb950c84dd
commit
0d4dded4cc
3 files changed
+28
-20
No files matched your search
-7
@@ -47,13 +47,6 @@ public class ClosedRegattaTest extends AbstractSeleniumTest {
|
||||
unregisteredCtx = createAnonymousApiContext(getContextRoot(), SERVER_CONTEXT);
|
||||
final AdminConsolePage adminConsole = goToPage(getWebDriver(), getContextRoot());
|
||||
adminConsole.goToLocalServerPanel().setSelfServiceServer(true);
|
||||
try {
|
||||
// FIXME: workaround for self service property not being set when the test method is called. Proper waiting
|
||||
// should be implemented...
|
||||
Thread.sleep(500);
|
||||
} catch (InterruptedException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
+11
@@ -19,7 +19,18 @@ public class LocalServerPO extends PageArea {
|
||||
public void setSelfServiceServer(boolean selfService) {
|
||||
if (selfService != isSelfServiceServerCheckbox.isSelected()) {
|
||||
isSelfServiceServerCheckbox.click();
|
||||
awaitServerConfigurationUpdated();
|
||||
}
|
||||
}
|
||||
|
||||
private void awaitServerConfigurationUpdated() {
|
||||
while (isServerConfigurationUpdating()) {
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isServerConfigurationUpdating() {
|
||||
final String updating = isSelfServiceServerCheckbox.getAttribute("updating");
|
||||
return "true".equals(updating);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user