Merge pull request #3308 from mhajas/KEYCLOAK-3694
KEYCLOAK-3694 Fix timeSkewTest on windows
This commit is contained in:
commit
f868aa7fbe
1 changed files with 4 additions and 0 deletions
|
@ -376,6 +376,8 @@ public abstract class AbstractJSConsoleExampleAdapterTest extends AbstractExampl
|
|||
|
||||
jsConsoleTestAppPage.refreshTimeSkew();
|
||||
|
||||
waitUntilElement(jsConsoleTestAppPage.getTimeSkewValue()).text().not().contains("undefined");
|
||||
|
||||
int timeSkew = Integer.parseInt(jsConsoleTestAppPage.getTimeSkewValue().getText());
|
||||
assertTrue("TimeSkew was: " + timeSkew + ", but should be ~0", timeSkew >= 0 - TIME_SKEW_TOLERANCE);
|
||||
assertTrue("TimeSkew was: " + timeSkew + ", but should be ~0", timeSkew <= TIME_SKEW_TOLERANCE);
|
||||
|
@ -384,6 +386,8 @@ public abstract class AbstractJSConsoleExampleAdapterTest extends AbstractExampl
|
|||
jsConsoleTestAppPage.refreshToken();
|
||||
jsConsoleTestAppPage.refreshTimeSkew();
|
||||
|
||||
waitUntilElement(jsConsoleTestAppPage.getTimeSkewValue()).text().not().contains("undefined");
|
||||
|
||||
timeSkew = Integer.parseInt(jsConsoleTestAppPage.getTimeSkewValue().getText());
|
||||
assertTrue("TimeSkew was: " + timeSkew + ", but should be ~-40", timeSkew + 40 >= 0 - TIME_SKEW_TOLERANCE);
|
||||
assertTrue("TimeSkew was: " + timeSkew + ", but should be ~-40", timeSkew + 40 <= TIME_SKEW_TOLERANCE);
|
||||
|
|
Loading…
Reference in a new issue