1.
Which of the following capabilities are mandatory for webapp automation
Correct Answer
C. BrowserName
Explanation
The "browserName" capability is mandatory for webapp automation. This capability is used to specify the name of the browser that will be used for the automation. It is necessary to define the browser in order for the automation to interact with it correctly. The other capabilities mentioned, such as "chromedriverExecutable", "automationName", and "version" are not mandatory for webapp automation, as they are not directly related to specifying the browser.
2.
Default WebdriverAgent port
Correct Answer
D. 8100
Explanation
The default WebdriverAgent port is 8100.
3.
Which of the following is not part of UiAutomator api's
Correct Answer
B. UiAttribute
Explanation
UiAttribute is not part of the UiAutomator API. The UiAutomator API is a framework provided by Android for writing automated UI tests. It includes classes and methods for interacting with the user interface of an Android application. However, UiAttribute is not one of the classes or methods provided by the UiAutomator API.
4.
Which of the below commands provides info only about real ios devices
Correct Answer
C. Ios-deploy -c
Explanation
The command "ios-deploy -c" provides information only about real iOS devices.
5.
Which is true about provisioning profile
a)Provisioning Profile will contain a set of iPhone Development Certificates, Unique Device Identifiers and an App ID.
b)Devices specified within the provisioning profile can only be used for testing.
c)A single device can contain multiple provisioning profiles.
Correct Answer
A. A B and C
Explanation
A provisioning profile is a file that contains a set of iPhone Development Certificates, Unique Device Identifiers (UDIDs), and an App ID. This profile is necessary for testing and deploying an app on a physical device. The devices specified within the provisioning profile can only be used for testing purposes. Additionally, a single device can contain multiple provisioning profiles, allowing for the installation and testing of multiple apps on the same device.
6.
What is the use of " ` " in iOS class chain
Correct Answer
C. Predicate expression is applied to all the current children of the current element
Explanation
The `" `" in iOS class chain is used to apply the predicate expression to all the current children of the current element. It allows the user to specify a condition that the children elements must meet in order to be selected. This helps in narrowing down the search and targeting specific elements within the class chain.
7.
Which of the following capabilities are not required as a part of automatic code signing
Correct Answer
A. XcodeTeamId
Explanation
The xcodeTeamId is not required as a part of automatic code signing. Automatic code signing allows Xcode to manage the signing process for you, including generating and managing certificates, provisioning profiles, and signing identities. The xcodeTeamId is used to specify the team identifier for manual code signing, where you have to manually manage the signing process. Therefore, it is not needed when using automatic code signing.
8.
"CHAIN" locator strategy default strategy used by androidAutomation in pageobject pattern
Correct Answer
A. True
Explanation
The statement is explaining that the "CHAIN" locator strategy is the default strategy used by androidAutomation in the page object pattern. This means that when using the page object pattern in Android automation, the "CHAIN" strategy is automatically used unless specified otherwise.
9.
Which is true about Hybrid apps
1)Combination of web and native
2)When debug is true, we can use browser to inspect elements.
3)When debug is false, we need to switch context to "webview" inorder to automate
Correct Answer
D. A and C
Explanation
Hybrid apps are a combination of web and native apps. They are built using web technologies such as HTML, CSS, and JavaScript, but are wrapped in a native container that allows them to be installed and run on a device like a native app. This combination allows hybrid apps to have access to device features and capabilities that are not available to web apps. Additionally, when debug is false, meaning when the app is in production mode, automation testing requires switching the context to "webview" in order to interact with the web elements of the hybrid app. Therefore, the correct answer is A and C.
10.
Is this a valid predicate locator: type == “XCUIElementTypeImage” AND label IN {“Tap”,“DoubleTap”}
Correct Answer
A. True
Explanation
This is a valid predicate locator because it uses the correct syntax and logical operators. The "type == 'XCUIElementTypeImage'" condition checks if the element type is an image, and the "label IN {'Tap', 'DoubleTap'}" condition checks if the label of the element is either "Tap" or "DoubleTap". The "AND" operator combines these two conditions, so the locator will only match elements that satisfy both conditions. Therefore, the answer is true.