File tree Expand file tree Collapse file tree 3 files changed +11
-5
lines changed
Expand file tree Collapse file tree 3 files changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -34,6 +34,12 @@ public class WebDriverFactory {
3434 private RemoteWebDriver remoteWebDriver ;
3535 private DesiredCapabilities capabilities ;
3636
37+ public WebDriverFactory () {
38+ capabilities = getCapabilities ();
39+ LOG .info ("Using capabilities: " + capabilities .toString ());
40+ remoteUrlPath = getRemoteUrlPath ();
41+ }
42+
3743 private static void setChromeDriver () {
3844 Platform platform = Platform .getCurrent ();
3945 String chromeBinary = "src/main/resources/drivers/chromedriver"
@@ -59,9 +65,6 @@ private static void setEdgeDriver() {
5965 }
6066
6167 public WebDriver getDriver () {
62- capabilities = getCapabilities ();
63- LOG .info ("Using capabilities: " + capabilities .toString ());
64- remoteUrlPath = getRemoteUrlPath ();
6568 if (isMobile ()) {
6669 driver = getMobileDriver ();
6770 LOG .info ("Start Mobile driver" );
Original file line number Diff line number Diff line change @@ -709,7 +709,11 @@ int getRetinaValue(int value) {
709709 return value ;
710710 }
711711 } else {
712- return value ;
712+ if (isIOS ()) {
713+ return 2 * value ;
714+ } else {
715+ return value ;
716+ }
713717 }
714718 }
715719
Original file line number Diff line number Diff line change @@ -19,7 +19,6 @@ public class UIValidator extends ResponsiveUIValidator implements Validator {
1919 heightRoot = rootElement .getSize ().getHeight ();
2020 pageWidth = (int ) getPageWidth ();
2121 pageHeight = (int ) getPageHeight ();
22- pageHeight = getRetinaValue (driver .manage ().window ().getSize ().getHeight ());
2322 startTime = System .currentTimeMillis ();
2423 }
2524
You can’t perform that action at this time.
0 commit comments