1919import org .openqa .selenium .remote .CapabilityType ;
2020
2121/**
22- * The list of iOS-specific capabilities.
23- * Read:
24- * https://github.com/appium/appium/blob/1.5/docs/en/writing-running-appium/caps.md#ios-only
22+ * The list of iOS-specific capabilities. <br>
23+ * Read: <br>
24+ * <a href="https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/caps.md#ios-only">
25+ * https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/caps.md#ios-only</a>
26+ * <br>
27+ * and<br>
28+ * <a href="https://github.com/appium/appium-xcuitest-driver#desired-capabilities">
29+ * https://github.com/appium/appium-xcuitest-driver#desired-capabilities</a>
2530 */
2631public interface IOSMobileCapabilityType extends CapabilityType {
2732
@@ -78,7 +83,7 @@ public interface IOSMobileCapabilityType extends CapabilityType {
7883 String NATIVE_INSTRUMENTS_LIB = "nativeInstrumentsLib" ;
7984
8085 /**
81- * (Sim-only) Enable "real", non-javascript-based web taps in Safari.
86+ * Enable "real", non-javascript-based web taps in Safari.
8287 * Default: false.
8388 * Warning: depending on viewport size/ratio this might not accurately tap an element.
8489 */
@@ -164,7 +169,7 @@ public interface IOSMobileCapabilityType extends CapabilityType {
164169 String APP_NAME = "appName" ;
165170
166171 /**
167- * Capability to pre-authorize a specific SSL cert in the iOS trust store .
172+ * (Sim only) Add an SSL certificate to IOS Simulator .
168173 */
169174 String CUSTOM_SSL_CERT = "customSSLCert" ;
170175
@@ -175,8 +180,11 @@ public interface IOSMobileCapabilityType extends CapabilityType {
175180 String TAP_WITH_SHORT_PRESS_DURATION = "tapWithShortPressDuration" ;
176181
177182 /**
178- * The capability to direct Appium to set the simulator scale.
179- * The XCUITest specific capability.
183+ * Simulator scale factor.
184+ * This is useful to have if the default resolution of simulated device is
185+ * greater than the actual display resolution. So you can scale the simulator
186+ * to see the whole device screen without scrolling.
187+ * This capability only works below Xcode9.
180188 */
181189 String SCALE_FACTOR = "scaleFactor" ;
182190
@@ -229,7 +237,10 @@ public interface IOSMobileCapabilityType extends CapabilityType {
229237 * creating tons of unnecessary screenshots and logs,
230238 * which are impossible to shutdown using programming
231239 * interfaces provided by Apple
240+ *
241+ * @deprecated This capability was deleted at Appium 1.14.0
232242 */
243+ @ Deprecated
233244 String PREVENT_WDAATTACHMENTS = "preventWDAAttachments" ;
234245
235246 /**
@@ -248,18 +259,28 @@ public interface IOSMobileCapabilityType extends CapabilityType {
248259 String KEYCHAIN_PATH = "keychainPath" ;
249260
250261 /**
251- * Forces uninstall of any existing WebDriverAgent app on device.
252- * This can provide stability in some situations. Defaults to false.
262+ * If {@code true}, forces uninstall of any existing WebDriverAgent app on device.
263+ * Set it to {@code true} if you want to apply different startup options for WebDriverAgent for each session.
264+ * Although, it is only guaranteed to work stable on Simulator. Real devices require WebDriverAgent
265+ * client to run for as long as possible without reinstall/restart to avoid issues like
266+ * <a href="https://github.com/facebook/WebDriverAgent/issues/507">
267+ * https://github.com/facebook/WebDriverAgent/issues/507</a>.
268+ * The {@code false} value (the default behaviour since driver version 2.35.0) will try to detect currently
269+ * running WDA listener executed by previous testing session(s) and reuse it if possible, which is
270+ * highly recommended for real device testing and to speed up suites of multiple tests in general.
271+ * A new WDA session will be triggered at the default URL (http://localhost:8100) if WDA is not
272+ * listening and {@code webDriverAgentUrl} capability is not set. The negative/unset value of {@code useNewWDA}
273+ * capability has no effect prior to xcuitest driver version 2.35.0.
253274 */
254275 String USE_NEW_WDA = "useNewWDA" ;
255276
256277 /**
257- * Time, in ms, to wait for WebDriverAgewnt to be pingable. Defaults to 60000ms.
278+ * Time, in ms, to wait for WebDriverAgent to be pingable. Defaults to 60000ms.
258279 */
259280 String WDA_LAUNCH_TIMEOUT = "wdaLaunchTimeout" ;
260281
261282 /**
262- * Timeout, in ms, for waiting for a resonse from WebDriverAgent. Defaults to 240000ms.
283+ * Timeout, in ms, for waiting for a response from WebDriverAgent. Defaults to 240000ms.
263284 */
264285 String WDA_CONNECTION_TIMEOUT = "wdaConnectionTimeout" ;
265286
@@ -273,7 +294,7 @@ public interface IOSMobileCapabilityType extends CapabilityType {
273294 /**
274295 * String representing a signing certificate.
275296 * Must be used in conjunction with xcodeOrgId.
276- * This is usually just iPhone Developer.
297+ * This is usually just iPhone Developer, so the default (if not included) is iPhone Developer
277298 */
278299 String XCODE_SIGNING_ID = "xcodeSigningId" ;
279300
@@ -288,13 +309,22 @@ public interface IOSMobileCapabilityType extends CapabilityType {
288309 * Whether to perform reset on test session finish (false) or not (true).
289310 * Keeping this variable set to true and Simulator running
290311 * (the default behaviour since version 1.6.4) may significantly shorten the
291- * duratiuon of test session initialization.
312+ * duration of test session initialization.
292313 * Defaults to true.
293314 */
294315 String RESET_ON_SESSION_START_ONLY = "resetOnSessionStartOnly" ;
295316
296317 /**
297318 * Custom timeout(s) in milliseconds for WDA backend commands execution.
319+ * This might be useful if WDA backend freezes unexpectedly or requires
320+ * too much time to fail and blocks automated test execution.
321+ * The value is expected to be of type string and can either contain
322+ * max milliseconds to wait for each WDA command to be executed before
323+ * terminating the session forcefully or a valid JSON string,
324+ * where keys are internal Appium command names (you can find these in logs,
325+ * look for "Executing command 'command_name'" records) and values are
326+ * timeouts in milliseconds. You can also set the 'default' key to assign
327+ * the timeout for all other commands not explicitly enumerated as JSON keys.
298328 */
299329 String COMMAND_TIMEOUTS = "commandTimeouts" ;
300330
0 commit comments