title,body,link,tags,view_count,is_answered,score,answer_count
UI testing firstMatch,"<p>Is it safe to replace all instances in my UI testing code of <code>.element(boundBy: 0)</code> with <code>.firstMatch</code>?</p>

<p>I would think so, but the documentation from Apple isn't very clear about it (especially in the case of multiple matches even though I only care about the first one).
<a href=""https://developer.apple.com/documentation/xctest/xcuielementtypequeryprovider/2902250-firstmatch"" rel=""nofollow noreferrer"">https://developer.apple.com/documentation/xctest/xcuielementtypequeryprovider/2902250-firstmatch</a></p>
",https://stackoverflow.com/questions/46276544/ui-testing-firstmatch,"['ios', 'xcode-ui-testing']",2627,TRUE,4,1
Simulators UI testing,"<p>I've read much about Simulators and Emulators but I could not find a precise (wording does not reflect a 100% sure answer to this question) answer to this questions:</p>

<p>When I run a Simualtor does it simulate the eg iOS Os exact, I mean when I test my UI in a simulator is it for sure going to be look the same on the device? </p>

<p><em>I have no concern in my app about memory usage or with some other hardware interactions, I just want to test my UI (ui not in terms of performance)...</em></p>
",https://stackoverflow.com/questions/42695215/simulators-ui-testing,"['ios', 'simulator']",26,FALSE,2,1
Xamarin.Forms UWP UI Testing,"<p>I am new to Xamarin.Forms and UWP and I am looking for more information on UI testing Xamarin.Forms UWP projects.</p>

<p>Can anyone provide more info about ways to UI test Xamarin.Forms UWP projects?</p>
",https://stackoverflow.com/questions/45023172/xamarin-forms-uwp-ui-testing,"['c#', 'uwp', 'xamarin.forms', 'ui-testing']",1013,TRUE,1,1
UI Testing Multiple UITextFields,"<p>I'm trying to create a UITest using the recording function for an app that contains multiple UITextFields per view. When trying to do so I'm having a couple issues. </p>

<p>To simplify the issue I have created an application with two text fields nested inside one subview as shown in the picture.</p>

<p><img src=""https://i.stack.imgur.com/0ugQ9.png"" alt=""single view controller with two UITextFields in a subview""></p>

<p>From here I opened the identity inspector and changed the label of the two UITextFields under the accessibility heading to 'topField' and 'bottomField' (accessibility disabled on the gray UIView). Then I went into the UITest 'testExample' function and click the record button. From here I click the top text field, type something in, then when I click the bottom text field I get this error 'Timestamped Event Matching Error: Failed to find matching element'. </p>

<p><img src=""https://i.stack.imgur.com/ElaAs.png"" alt=""Xcode pop up alert""></p>

<p>What am I missing here? I know this is a result of Xcode not being able to find the text field in the hierarchy, but I don't know why since I have given labels to each element in accessibility. I am able to manually write the code into the testing method to access the second text field without any errors, but the recording is not working. Any help is greatly appreciated. </p>
",https://stackoverflow.com/questions/44747562/ui-testing-multiple-uitextfields,"['ios', 'xcode', 'uitextfield', 'ios-ui-automation']",206,FALSE,0,0
UI Testing with XCUI,"<p>I'm trying for unit testing of view controllers in xCode 8. I'm able to record, assert and run it successfully using XCUI. But I want to test particular view controller independently. </p>

<p>Like there are 4 controllers A,B,C and D in sequence    (A->B->C->D). I want to directly launch C controller and test it independently. </p>

<p>I'm able to test in this way i.e. default XCUIApplication will open A controller then click on something you will go to B Controller and then click on button in B will take you to C Controller. Then you can test it out. But I don't want in sequence. I want to directly test C controller.</p>

<p>Can you please help if anyone else has done same kind of job. 
Thanks in advance.</p>
",https://stackoverflow.com/questions/42130343/ui-testing-with-xcui,"['ios', 'unit-testing', 'swift3', 'xcode8', 'ios10']",1274,TRUE,0,2
Visual Studio UI Testing,"<p>I have done some extravagant web searching for a solution to no avail.</p>

<p>I am working with a UI tester written by a man who is no longer with the company.</p>

<p>Currently it is hanging up on opening the browser for testing the website.</p>

<p>I have no idea what I'm doing.</p>

<pre><code>BrowserWindow.CurrentBrowser = ""ie"";
</code></pre>

<blockquote>
  <p>""An unhandled exception of type 'System.IO.FileNotFoundException' occurred in Microsoft.VisualStudio.TestTools.UITesting.dll</p>
  
  <p>Additional information: Could not load file or assembly 'Microsoft.VisualStudio.TestTools.UITest.WindowsStoreUtility, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.""</p>
</blockquote>
",https://stackoverflow.com/questions/46456305/visual-studio-ui-testing,"['c#', 'visual-studio-2015', 'ui-testing']",201,TRUE,0,1
UI Testing UITableView cell count,"<p>I'm trying to verify that a table view has been filled with a certain number of cells in my UI test. Here is my code:</p>

<pre><code>XCUIApplication().tables.element.swipeUp()
let count = XCUIApplication().tables.element.children(matching: .cell).count
XCTAssert(count &gt; 0)
</code></pre>

<p>The assert fails because the <code>count</code> is always 0, even though the swipe up scrolls the obviously successfully filled table view. I have also tried:</p>

<pre><code>XCTAssert(app.tables.cells.count &gt; 0)
</code></pre>

<p>with the same results. I even created an empty project with a table view with 3 static cells, in just one screen, to remove any other possible distractions for the UI test, and it still always returns 0. I'm testing on iOS 11 with Xcode 9.</p>
",https://stackoverflow.com/questions/48005381/ui-testing-uitableview-cell-count,"['ios', 'uitableview', 'automated-tests', 'tdd', 'xcode-ui-testing']",6889,TRUE,3,2
Error 25201 : UI Testing Failure,"<p>While doing UITest i got this error. </p>

<p>I am using xcode 8.2.1 </p>

<pre><code>Assertion Failure: UI Testing Failure - Failure getting snapshot Error Domain=XCTestManagerErrorDomain Code=9 ""Error -25201 getting snapshot for element &lt;AXUIElement 0x7faf7b4173f0&gt; {pid=84523}"" UserInfo={NSLocalizedDescription=Error -25201 getting snapshot for element &lt;AXUIElement 0x7faf7b4173f0&gt; {pid=84523}}
</code></pre>

<p>I tried deleting DerivedData, Pods/, Podfile.lock and *.xcworkspace and running pod install afterwards. No luck. Still experiencing the error. First experienced in Xcode 7.3. Upgraded it and issue still persists.</p>

<p>Anybody who experienced the same thing? Kindly share here...</p>

<p>Any help will be Appreciated...Thank you. </p>
",https://stackoverflow.com/questions/42067957/error-25201-ui-testing-failure,"['ios', 'xcode', 'xcode-ui-testing']",311,FALSE,2,0
Increase iOS UI-testing speed,"<p>I've been reading tricks to speed up iOS UITesting by increasing the Core Animation speed. What does the following value represent? What are the minimum and maximum values?</p>
<pre><code>UIApplication.sharedApplication.keyWindow.layer.speed = 100;
</code></pre>
",https://stackoverflow.com/questions/42081265/increase-ios-ui-testing-speed,"['ios', 'xcode-ui-testing', 'ui-testing']",1181,TRUE,0,1
Call button on UI Testing?,"<p>I was wondering if it's possible to tap call button from tel's scheme (e.g tel//555555555). Because if I touch call button I'll have an alert that I need to confirm my call or cancel it. Is it possible?</p>

<p>I have this on my code:</p>

<pre><code>addUIInterruptionMonitor(withDescription: ""Phone Dialog"") { (alert) -&gt; Bool in
        let button = alert.buttons[""Llamar""]
        if button.exists {
            button.tap()
            return true
        }
        return false
    }
    app.tap()
    XCTAssert(app.buttons[""call_button""].exists, ""No se encuentra el boton de llamar"")
    app.buttons[""call_button""].tap()
    sleep(2)
</code></pre>

<p>Any Idea?
Regards</p>
",https://stackoverflow.com/questions/46322758/call-button-on-ui-testing,"['ios', 'swift', 'xcode-ui-testing']",861,TRUE,0,1
iOS UI Testing vs Integration Testing,"<p>So I've been trying to read about UI and Integration testing (specifically for iOS development). I always though these tests were different, but a lot of the integration tests example I see, appear to be what I would call UI testing. </p>

<p>So now I'm curious, what is the difference between UI and integration testing? Could you please give examples?</p>
",https://stackoverflow.com/questions/46625010/ios-ui-testing-vs-integration-testing,"['ios', 'xcode', 'unit-testing', 'integration-testing', 'ui-testing']",5304,TRUE,7,1
Does Selenium do UI testing?,"<p>I was wondering if we can use selenium for UI testing.  Does it support Javascripts on modern browsers?  What other open source tools do you recommend?
I have googled a bit but could not get any definitive answer.  </p>

<p>Thank you</p>
",https://stackoverflow.com/questions/42794211/does-selenium-do-ui-testing,"['selenium', 'selenium-webdriver']",110,TRUE,0,1
Espresso Nested Recycler Views UI testing,"<p>I have a Horizontal <code>RecyclerView</code> inside a vertical <code>RecyclerView</code>. I'm using this code I found on other question:</p>

<pre><code>onView(allOf(isDescendantOfA(withRecyclerView(R.id.parentVerticalRecyclerView).atPosition(parentPosition)),
             isDescendantOfA(withRecyclerView(R.id.childHorizontalRecyclerView).atPosition(childPosition)),
                (withText(""USA""))))
                .perform(click());

// It is not working for parentPosition &gt; 0
</code></pre>

<p>but this only works for first row of parent <code>RecyclerView</code>.</p>

<p>How do I click on the element on the child RecyclerView of the second row of parent <code>RecyclerView</code>?</p>
",https://stackoverflow.com/questions/43088830/espresso-nested-recycler-views-ui-testing,"['java', 'android', 'android-recyclerview', 'ui-testing', 'android-espresso']",1087,TRUE,4,1
Failure getting snapshot on UI Testing,"<p>I'm trying to select a cell from table view in UI Testing with that code:</p>

<pre><code>let clientTable = app.tables
XCTAssert(clientTable.cells.count &gt; 0)
clientTable.cells.element(boundBy: 0).tap()
</code></pre>

<p>The problem is when I'm run that test on device and even in simulators I have this error:</p>

<pre><code>Assertion Failure: &lt;unknown&gt;:0: Failure getting snapshot Error Domain=XCTDaemonErrorDomain Code=9 
""Error -25204 getting snapshot for element &lt;AXUIElement 0x7f9ddea00e10&gt; {pid=22751}"" 
UserInfo={NSLocalizedDescription=Error -25204 getting snapshot for 
element &lt;AXUIElement 0x7f9ddea00e10&gt; {pid=22751}}
</code></pre>

<p>What could be happening?</p>
",https://stackoverflow.com/questions/45507558/failure-getting-snapshot-on-ui-testing,"['ios', 'testing', 'xcode-ui-testing']",101,FALSE,1,0
Xamarin UI Testing for Android app,"<p>I have developed xamarin hybrid app (html5 , css &amp; js) for android. Now I am working on testing my android app on xamarin test cloud using xamarin ui testing. I have implemented file upload control (html5) in my app and I want to test file upload feature on xamarin cloud for all devices. Is this possible to test file upload feature using xamarin ui testing.</p>

<p>Thanks in advance. </p>
",https://stackoverflow.com/questions/42718682/xamarin-ui-testing-for-android-app,"['html', 'xamarin', 'xamarin.android', 'ui-testing', 'xamarin-test-cloud']",237,FALSE,0,1
UI testing for react native apps,"<p>i am currently working on a UI automated testing project.</p>

<p>my job is to do UI automated testing on applications built via react-native.</p>

<p>the problem is that react-native doesn't provide resource-id.</p>

<p>i tried nativeID, and testID, and it didn't work out.</p>

<p>i tried accessibilityLabel but this is not the way to do it, because it assigns to the content-descp: which is used by the blind mode.</p>

<p>i tried cavy which is an integrated-ui testing tool, but it's very new, and there is not much support, plus it's not quit developped yet.</p>

<p>i tried selendroid, but i am facing some problems while loading the app in the local selendroid server, i think it has something to do with react native.</p>

<p>any help please!</p>
",https://stackoverflow.com/questions/45168567/ui-testing-for-react-native-apps,"['user-interface', 'testing', 'react-native', 'ui-testing']",1476,TRUE,0,2
Find table cell in Xcode ui testing Swift,"<p>I am new on Xcode + ios testing. I am going to automate ui of an existing ios project in swift. The problem is that I am unable to find table view of a view. Here is my code which i used to finding a cell from table view but this is not working in this case:</p>

<pre><code>XCUIApplication().tables.cells.allElementsBoundByIndex[1].tap()
</code></pre>

<p>I am attaching screenshot of the view flow. The ios code of view is not written by me.<a href=""https://i.stack.imgur.com/lktsG.png"" rel=""noreferrer""><img src=""https://i.stack.imgur.com/lktsG.png"" alt=""The events table view which I need to find in my ui testing""></a></p>
",https://stackoverflow.com/questions/44431136/find-table-cell-in-xcode-ui-testing-swift,"['ios', 'objective-c', 'swift', 'xcode', 'xcode-ui-testing']",13403,TRUE,12,4
How to view app logging when ui testing,"<p>When running UI tests on my iOS app on our Jenkins CI slave, the UI is incorrect and my tests fail. Locally, the same UI is as expected and the tests pass.</p>

<p>I haven't been able to figure this out and I cannot debug it as it is on a remote machine. So, I would like to add logging to see what decisions are being made by the app to figure out why the UI is displaying incorrectly in the remote Jenkins slave.</p>

<p>The test log output does not contain log output from the app (via <code>NSLog</code>), nor can I find any of the strings from the app<code>NSLog</code> calls in any .xcactivitylog file in the derived data output folders.</p>

<p>Where can I find my logging output from my app when it is being run by the UI tests? This is with Xcode 8.2 running a iOS 9.3 simulated device.</p>
",https://stackoverflow.com/questions/41487649/how-to-view-app-logging-when-ui-testing,"['xctest', 'xcode-ui-testing', 'ui-testing']",3715,TRUE,11,1
Get title of UIBarButtonItem while UI testing,"<p>I have a UIBarButtonItem inside a Toolbar and I have assigned an accessibility label and a title to it:</p>

<p><a href=""https://i.stack.imgur.com/QAy7b.png"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/QAy7b.png"" alt=""enter image description here""></a></p>

<p>When I am UI testing, I can catch the button with this query (or Xcode does it for me when I'm recording):</p>

<pre><code>        app.toolbars.buttons[""AreaCachingButton""].tap()
</code></pre>

<p>Then, I m trying to verify its title:</p>

<pre><code>        XCTAssertEqual(app.toolbars.buttons[""AreaCachingButton""].title, ""Abort Downloading"")
</code></pre>

<p>but I cannot because the title is empty, although I obviously see its title on my phone.</p>

<p>Any tips on how to solve/circumvent this?</p>
",https://stackoverflow.com/questions/43375439/get-title-of-uibarbuttonitem-while-ui-testing,"['ios', 'xcode', 'uibarbuttonitem', 'ui-testing']",672,FALSE,2,0
Application closes after launch during UI testing,"<p>I am trying to run UI testing on an android application with espresso but when I run the test on a mobile device or an emulator the application opens and suddenly it closes itself way to fast, even before the test is ran. </p>

<p>It is not that the application is crashing, it just closes as soon as it opens only when a test is ran. I am not sure what I am missing in the test configuration that provokes this behavior.</p>

<p>this is my gradle file</p>

<pre><code>apply plugin: 'com.android.application'
apply plugin: 'realm-android'

android {
compileSdkVersion 25
buildToolsVersion '25.0.3'

defaultConfig {
    applicationId ""com.test1""
    minSdkVersion 14
    targetSdkVersion 25
    versionCode 1
    versionName ""1.0""
    testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner'
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.android.support:support-v4:25.3.1'
compile 'com.android.support:recyclerview-v7:25.3.1'
compile 'com.android.support:cardview-v7:25.3.1'
compile 'com.android.support:design:25.3.1'
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'jp.wasabeef:picasso-transformations:2.1.2'
compile 'com.google.firebase:firebase-database:9.4.0'
compile 'com.google.firebase:firebase-auth:9.4.0'
compile 'com.google.firebase:firebase-messaging:9.4.0'
compile 'com.google.android.gms:play-services-location:9.4.0'
compile 'com.google.android.gms:play-services-places:9.4.0'
compile 'com.squareup.retrofit2:retrofit:2.3.0'
compile 'com.squareup.retrofit2:converter-gson:2.1.0'
androidTestCompile ('com.android.support.test:runner:1.0.1') {
    exclude module: 'support-annotations'
}
androidTestCompile ('com.android.support.test:rules:1.0.1') {
    exclude module: 'support-annotations'
}
androidTestCompile ('com.android.support.test.espresso:espresso-intents:3.0.1') {
    exclude module: 'support-annotations'
}
androidTestCompile ('com.android.support.test.espresso:espresso-web:3.0.1') {
    exclude module: 'support-annotations'
}
androidTestCompile ('com.android.support.test.espresso:espresso-core:3.0.1') {
    exclude module: 'support-annotations'
}
}

apply plugin: 'com.google.gms.google-services'
</code></pre>

<p>this is my test</p>

<pre><code>@RunWith(AndroidJUnit4.class)
public class PAC4Testing {


@Rule
public ActivityTestRule&lt;BookListActivity&gt; mActivityRule = new ActivityTestRule&lt;&gt;(
        BookListActivity.class);


@Test
public void checkLoadedList() {
   if (getRVcount() &gt; 0){
        assertEquals(9,getRVcount());
    }
}

private int getRVcount(){
    RecyclerView recyclerView = (RecyclerView) mActivityRule.getActivity().findViewById(R.id.book_list);
    return recyclerView.getAdapter().getItemCount();
}

@Test
public void checkMenuOpened() {

}

@Test
public void checkLoadedWebViewFromDetail() {

}
}
</code></pre>

<p>Thanks!</p>

<p>EDIT these are logs, there is an error when the test is ran because the application closes, the test cant find anything on the screen.</p>

<pre><code>java.lang.NullPointerException: Attempt to invoke virtual method 'int 

android.support.v7.widget.RecyclerView$Adapter.getItemCount()' on a null object reference
at PAC4Testing.getRVcount(PAC4Testing.java:34)
at PAC4Testing.checkLoadedList(PAC4Testing.java:27)
at java.lang.reflect.Method.invoke(Native Method)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at android.support.test.rule.ActivityTestRule$ActivityStatement.evaluate(ActivityTestRule.java:433)
at org.junit.rules.RunRules.evaluate(RunRules.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runners.Suite.runChild(Suite.java:128)
at org.junit.runners.Suite.runChild(Suite.java:27)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
at android.support.test.internal.runner.TestExecutor.execute(TestExecutor.java:58)
at android.support.test.runner.AndroidJUnitRunner.onStart(AndroidJUnitRunner.java:375)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1886)
</code></pre>
",https://stackoverflow.com/questions/47978440/application-closes-after-launch-during-ui-testing,"['android', 'gradle', 'junit4', 'android-espresso']",209,TRUE,1,2
Test object state during UI testing (iOS),"<p>Is it possible to test object state (global variable, singleton object) during UI test? For example, I have UI test where some buttons were tapped and text entered to a textfield. I want to assert that object state changes correctly based on user input.</p>
",https://stackoverflow.com/questions/47071659/test-object-state-during-ui-testing-ios,"['ios', 'swift', 'testing', 'xcode-ui-testing']",627,TRUE,0,1
Writing a Stored Procedure for UI testing,"<p>I have a web application for which I have been loading data manually (Some SQL inserts statements) for testing purposes. So every time I load data with different values. I thought of creating a <code>Stored Procedure</code> but even in Stored Procedure whoever is loading the data for testing has to change the values. Not sure if I am thinking the right way.</p>

<p>For instance, this is what I have right now:</p>

<pre><code>INSERT INTO DOCUMENT_SET (DOCUMENT_SET_TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'M1', getDate(), getDate(), 1); 
</code></pre>

<p>So I insert above script around 10 times with different values for one transaction. For another transaction, I have to insert this again 10 times with different values.</p>

<p>Now if I create a stored procedure:</p>

<pre><code>Create Procedure Transaction
As
Begin
    INSERT INTO esg.DOCUMENT_SET_TRANS_MDATA (DOCUMENT_SET_TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'M1', getDate(), getDate(), 1); 

    9 more times with different values for one transaction
End
</code></pre>

<p>So for another transaction, someone has to change the values anyways then what is the benefit of writing a procedure in this situation?</p>

<p>Thanks</p>
",https://stackoverflow.com/questions/46162347/writing-a-stored-procedure-for-ui-testing,"['sql', 'sql-server', 'database']",152,TRUE,0,1
iOS - UI Testing Find Image In TableViewCell,"<p>I'm writing UI tests for my almost finished, Objective-C coded app as a newbie at UI tests. </p>

<p>I have a UITableView with custom cells. A cell either has text view or image or progress view. Image or progress view is set dynamically. 
For my tests, I need to check whether image was set or not. I tried to use <code>accessibilityIdentifier</code> property. I set it in the initialization method of that cell as:</p>

<pre><code>self.thumbnailImageView.isAccessibilityElement = YES;
self.thumbnailImageView.accessibilityIdentifier = @""imageLabel""
</code></pre>

<p>In my tests, I get the cell and tried to get it's elements depending on identifier like:</p>

<pre><code>XCUIElementQuery *tablesQuery = app.tables;
XCUIElementQuery *cellsQuery = app.tables.cells;
XCUIElement *lastCell = [[tablesQuery childrenMatchingType:XCUIElementTypeCell] elementBoundByIndex:(cellsQuery.count - 1)];
XCUIElement *image = lastCell.otherElements[@""imageLabel""];
</code></pre>

<p>I didn't get image from app.otherElements because there are multiple cells created and many of them may have an image view. I want to check last cell and it's image. 
After this, I set an assert as:</p>

<pre><code>XCTAssertTrue(image.exists, @""Image cell has failed"");
</code></pre>

<p>It's never passing this test and also enters in an exception breakpoint (?). I check situation of image, it's not nil. </p>

<p>I don't know what to do exactly. For Objective-C, there is almost no document for UI testing. Still Swift documents would be good but they are not enough too. </p>

<p>Any help would be very good. Thank you!</p>
",https://stackoverflow.com/questions/44841051/ios-ui-testing-find-image-in-tableviewcell,"['ios', 'objective-c', 'xctest', 'xcode-ui-testing', 'uiaccessibility']",954,FALSE,0,1
"Vaadin UI Testing getPage(),getLocation() with JUnit4","<p>I am trying to test one of the classes which has a Vaadin UI parameters,</p>

<p>at the test execution level i have a null pointer exception</p>

<pre><code>String basePath = getBasePath();
</code></pre>

<p>This part can not be reached by the test case because of the getBasePath() method is not reachable due to NullPointerException.</p>

<pre><code>protected String getBasePath(){
    String basePath = """";

    String host = UI.getCurrent().getPage().getLocation().getHost();
    int port = UI.getCurrent().getPage().getLocation().getPort();
    String path_app = UI.getCurrent().getPage().getLocation().getPath();
    String http_s = UI.getCurrent().getPage().getLocation().getScheme();
</code></pre>

<p>So in this part of this code,I tested that </p>

<pre><code>UI.getCurrent().getPage()
</code></pre>

<p>Has a result, It is not null and test can reach to it. But the getLocation() has a null pointer exception.</p>

<pre><code>@Before
public void init() throws URISyntaxException, NoSuchFieldException, SecurityException {

    TetUI tetUI = new TetUI();
    UI.setCurrent(tetUI);
    UI.getCurrent().getPage().setLocation(""Something"");
      }
</code></pre>

<p>I set the Location like that or could be a URI as well, But it is still null.</p>

<p>I tried to have some other sources about the topic on the internet and nothing came out yet.</p>

<p>Maybe i do it in a completely wrong way , Is this approach is correct? Any suggestions ?</p>
",https://stackoverflow.com/questions/47032894/vaadin-ui-testing-getpage-getlocation-with-junit4,"['java', 'vaadin', 'junit4']",396,FALSE,0,1
iOS UI testing for XMPP based app,"<p>I have XMPP based app that is something like chat. I use <a href=""https://github.com/robbiehanson/XMPPFramework"" rel=""nofollow noreferrer"">XMPPFramework</a> for XMPP implementation. I would like to make UI testing where I need to send messages from different users. So I need to have mocking or two instances of app at the same time.</p>

<p>Is there framework for mocking or stubbing xmpp server like <a href=""https://github.com/AliSoftware/OHHTTPStubs"" rel=""nofollow noreferrer"">OHTTPStubs</a>?</p>

<p>Is there a way to run tests simultaneously with ability to specify which test methods should be run? </p>

<p>I tried to use <a href=""https://github.com/linkedin/bluepill"" rel=""nofollow noreferrer"">Bluepill</a> for it but it seems that it doesn't fit for my purpose.</p>
",https://stackoverflow.com/questions/42364152/ios-ui-testing-for-xmpp-based-app,"['ios', 'swift', 'testing', 'xmpp', 'xmppframework']",91,FALSE,0,0
Xamarin.Forms UI Testing- Timed out waiting for keyboard,"<p>After Selecting <em>Hardware->Keyboard->Toggle Software Keyboard</em> still its not working.</p>

<blockquote>
  <p>Error while performing EnterText(Marked(""Password""), ""asdfg"")<br>
  Exception: System.TimeoutException: Timed out waiting for keyboard.<br>
  at Xamarin.UITest.Shared.WaitForHelper.WaitFor (System.Func 1[TResult]
  predicate, System.String timeoutMessage, System.Nullable 1[T] timeout,
  System.Nullable 1[T] retryFrequency, System.Nullable 1[T] postTimeout)
  [0x000ff] in &lt;40cdba9629c64993881ff8259cae4300>:0<br>
  at Xamarin.UITest.iOS.iOSApp+c__AnonStorey6.&lt;>m__0 ()
  [0x00165] in &lt;40cdba9629c64993881ff8259cae4300>:0<br>
  at Xamarin.UITest.Utils.ErrorReporting.With (System.Action func,
  System.Object[] args, System.String memberName) [0x00006] in
  &lt;40cdba9629c64993881ff</p>
</blockquote>
",https://stackoverflow.com/questions/46622770/xamarin-forms-ui-testing-timed-out-waiting-for-keyboard,"['xamarin', 'xamarin.ios', 'xamarin.uitest']",880,FALSE,2,1
Xcode UI Testing: Automatically taking snapshot when predicates fail?,"<p>Xcode UI Testing takes automatic screenshots for viewing in the results navigator whenever a test fails, which is greatly helpful. However, that does not include tests that fail because a predicate is failed. Since predicates are often for basic checks (such as if an element exists or not on a current view), that is a huge drawback because a screenshot would be useful in diagnosing what was happening in the app when the test failed.</p>

<p>Does anyone know how to force a screenshot? Does this require integrating the Fastlane Snapshot tool?</p>
",https://stackoverflow.com/questions/43082210/xcode-ui-testing-automatically-taking-snapshot-when-predicates-fail,"['xcode', 'xctest', 'xcode-ui-testing']",5450,TRUE,7,3
Using Docker to create &quot;restorable&quot; MySQL database for UI testing,"<p>We have a number of selenium tests that run on a production-like setup of our webapp. The problem is that some of the tests do stuff in the application that affects the database.</p>

<p>Would it be possible to have a data volume or similar, that we can ""clone"" and attach to a container before every test?</p>

<p>We really just need a MySQL database that can be quickly recreated before every test. And once in a while we would run schema migrations to that database.</p>

<p>Or is there another approach that would be more suited for this?</p>
",https://stackoverflow.com/questions/41965815/using-docker-to-create-restorable-mysql-database-for-ui-testing,"['mysql', 'selenium', 'docker']",2115,TRUE,13,2
Accessibility element not a descendant in UI Testing,"<p>I have a UITextField inside a UIView loaded from a nib, it has <code>isAccessiblityElement</code> set to true, all of it's superviews do not have it set. It has an <code>accessbilityIdentifier</code> set to <code>Search Field</code>.</p>

<p>The view is loaded from the nib, and set to a navigationItem's <code>titleView</code>.
However when doing UI Testing I can't find the element using the identifier. </p>

<p>Printing a debugDescription of the whole hierarchy of descendants from the root of the app only shows up to the view loaded from the nib, even though it isn't an accessibility element. There is no element anywhere in the hierarchy that has the identifier <code>Search Field</code>.</p>

<p>Is there something else that needs to be done to make the <code>UITextField</code> appear in the hierarchy and become an queryable ui element, so that UI tests can interact with it.</p>
",https://stackoverflow.com/questions/46954529/accessibility-element-not-a-descendant-in-ui-testing,"['ios', 'xcode-ui-testing']",1797,TRUE,0,2
Issue facing for xcode-ui-testing in XCode 9,"<p>UI Test for an ios-app, developed in XCode 8 and swift 3.2.</p>

<p>Facing problem to deal with ScrollViews, collectionViews after upgrade XCode to 9  </p>

<p>I can tap and access the Buttons, StaticTexts, TextFields elements.
But I can not tap or access the collectionviews, scrollviews, tableviews elements on XCode9 and Swift 3.2.</p>

<p>Suppose in the previous XCode version (i.e, XCode 8.3) I used the code <code>app.collectionViews.collectionViews.cells.images.element(boundBy: 0).tap()</code><br>
to tap on Home page(collectionViews). But this code is not working in XCode 9.</p>

<p>I tried to get the exact element using uitest recording feature.
By using recording I got the code - </p>

<pre><code>app.collectionViews.otherElements.containing(.textField, identifier:""StoryboardTitleTextField"").children(matching: .collectionView).element.tap().
</code></pre>

<p>But this code isn't working too. So how can I resolve this?</p>

<p>Thanks</p>
",https://stackoverflow.com/questions/47268421/issue-facing-for-xcode-ui-testing-in-xcode-9,"['ios', 'xcode', 'ios-ui-automation', 'swift3.2']",426,TRUE,3,1
Android Espresso: UI-Testing with an Ionic Cordova Build,"<p>Im trying to test the <strong>Android-Build</strong> of an Ionic <strong>Cordova</strong> application with the <strong>Espresso</strong> testing tool from <strong>Android Studio</strong>.</p>

<p>After several dependency issues, the test environment now works. But when I create a test with 'Run -> Record Espresso Test' by selecting elements with the assertion function and run the test afterward, it fails. </p>

<p>The <strong>element cant found</strong> in the views hierarchy. I have no idea why. I already tried so many things, I've also created non-generated test cases identifying elements but vainly.</p>

<p>Does somebody have experience with testing Android-Builds from Ionic Cordova with Android Studios Espresso testing environment?</p>

<p>Hope somebody can help me!</p>

<p><strong>Test:</strong> (Generated with Espresso)</p>

<pre><code>@LargeTest
@RunWith(AndroidJUnit4.class)
public class ExistReportButton {

    @Rule
    public ActivityTestRule&lt;MainActivity&gt; mActivityTestRule = new ActivityTestRule&lt;MainActivity&gt;(MainActivity.class);

    @Test
    public void existReportButton() {
        // Added a sleep statement to match the app's execution delay.
        // The recommended way to handle such scenarios is to use Espresso idling resources:
        // https://google.github.io/android-testing-support-library/docs/espresso/idling-resource/index.html
        try {
            Thread.sleep(59700);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }

        ViewInteraction button = onView(
                allOf(withContentDescription(""\uF101 Create a Report ""),
                        childAtPosition(
                                childAtPosition(
                                        IsInstanceOf.&lt;View&gt;instanceOf(android.view.View.class),
                                        0),
                                0),
                        isDisplayed()));
        button.check(matches(isDisplayed()));
    }

    private static Matcher&lt;View&gt; childAtPosition(
            final Matcher&lt;View&gt; parentMatcher, final int position) {

        return new TypeSafeMatcher&lt;View&gt;() {
            @Override
            public void describeTo(Description description) {
                description.appendText(""Child at position "" + position + "" in parent "");
                parentMatcher.describeTo(description);
            }

            @Override
            public boolean matchesSafely(View view) {
                ViewParent parent = view.getParent();
                return parent instanceof ViewGroup &amp;&amp; parentMatcher.matches(parent)
                        &amp;&amp; view.equals(((ViewGroup) parent).getChildAt(position));
            }
        };
    }
}
</code></pre>

<p><strong>Error:</strong> </p>

<pre><code>android.support.test.espresso.NoMatchingViewException: No views in hierarchy found matching: (with content description: is "" Create a Report "" and Child at position 0 in parent Child at position 0 in parent an instance of android.view.View and is displayed on the screen to the user)

View Hierarchy:
+&gt;DecorView{id=-1, visibility=VISIBLE, width=480, height=854, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+-&gt;LinearLayout{id=-1, visibility=VISIBLE, width=480, height=854, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=2}
|
+--&gt;ViewStub{id=16908679, res-name=action_mode_bar_stub, visibility=GONE, width=0, height=0, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=true, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+--&gt;FrameLayout{id=16908290, res-name=content, visibility=VISIBLE, width=480, height=818, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=36.0, child-count=1}
|
+---&gt;FrameLayout{id=-1, visibility=VISIBLE, width=480, height=818, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=3}
|
+----&gt;SystemWebView{id=100, visibility=VISIBLE, width=480, height=818, has-focus=true, has-focusable=true, has-window-focus=true, is-clickable=true, is-enabled=true, is-focused=true, is-focusable=true, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0, child-count=0}
|
+----&gt;ImageView{id=-1, visibility=VISIBLE, width=480, height=818, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+----&gt;ImageView{id=-1, visibility=VISIBLE, width=480, height=818, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
+-&gt;View{id=16908335, res-name=statusBarBackground, visibility=VISIBLE, width=480, height=36, has-focus=false, has-focusable=false, has-window-focus=true, is-clickable=false, is-enabled=true, is-focused=false, is-focusable=false, is-layout-requested=false, is-selected=false, root-is-layout-requested=false, has-input-connection=false, x=0.0, y=0.0}
|
at dalvik.system.VMStack.getThreadStackTrace(Native Method)
at java.lang.Thread.getStackTrace(Thread.java:1538)
at android.support.test.espresso.base.DefaultFailureHandler.getUserFriendlyError(DefaultFailureHandler.java:92)
at android.support.test.espresso.base.DefaultFailureHandler.handle(DefaultFailureHandler.java:56)
at android.support.test.espresso.ViewInteraction.runSynchronouslyOnUiThread(ViewInteraction.java:184)
at android.support.test.espresso.ViewInteraction.check(ViewInteraction.java:158)
at org.capacitylab.mobile4d.ExistReportButton.existReportButton(ExistReportButton.java:60)
at java.lang.reflect.Method.invoke(Native Method)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at android.support.test.internal.statement.UiThreadStatement.evaluate(UiThreadStatement.java:55)
at android.support.test.rule.ActivityTestRule$ActivityStatement.evaluate(ActivityTestRule.java:270)
at org.junit.rules.RunRules.evaluate(RunRules.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runners.Suite.runChild(Suite.java:128)
at org.junit.runners.Suite.runChild(Suite.java:27)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
at android.support.test.internal.runner.TestExecutor.execute(TestExecutor.java:59)
at android.support.test.runner.AndroidJUnitRunner.onStart(AndroidJUnitRunner.java:262)
at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:2075)

Tests ran to completion.
</code></pre>
",https://stackoverflow.com/questions/47309812/android-espresso-ui-testing-with-an-ionic-cordova-build,"['android', 'cordova', 'hybrid-mobile-app', 'android-espresso', 'ui-testing']",886,TRUE,1,1
Accessibility identifiers stopped finding elements used for UI testing,"<p>I've set up accessibility identifiers in the storyboard. These were working. However, I enabled accessibility on more views and now none of the elements can be found using the accessibility identifiers.</p>

<p>But, I can still find elements using the code generated by the record function.</p>

<p>Here's how I'm finding the elements: </p>

<pre><code>XCUIApplication().buttons[""loginButton""] //loginButton is the accessibility identifier
</code></pre>

<p>Here's how that same button is found using the recorder: </p>

<pre><code>XCUIApplication().children(matching: .window).element(boundBy: 0).children(matching: 
.other).element.children(matching: .other).element.children(matching: 
.other).element.children(matching: .other).element.tap()
</code></pre>

<p>The error that I'm getting is: </p>

<pre><code>No matches found for *typeOfElement*
</code></pre>

<p>I haven't been able to find an applicable solution online so far.</p>

<p><strong>My question a nutshell:</strong> Why can't I get a reference to elements using the accessibility identifiers.</p>

<p>Thanks in advance.</p>
",https://stackoverflow.com/questions/44478459/accessibility-identifiers-stopped-finding-elements-used-for-ui-testing,"['ios', 'swift', 'xcode', 'xctest', 'xcode-ui-testing']",2048,TRUE,1,1
Requirements for Creating A New Coded UI Testing Project In VS2017 Enterprise,"<p>I've just installed <em>Visual Studio 2017</em> <strong>Enterprise</strong> (15.0.26228.4 D15RTWSVC) with .NET Framework Version 4.6.01055. I cannot add a new coded UI test project to a new solution because I cannot find that project type in the 'New Project' dialog. I assume it's because I didn't install some optional module when I was installing Visual Studio.</p>

<p>Which optional module do I need to install to be able to add new Coded UI test projects to solutions in VS2017 Enterprise?</p>
",https://stackoverflow.com/questions/42788695/requirements-for-creating-a-new-coded-ui-testing-project-in-vs2017-enterprise,"['coded-ui-tests', 'visual-studio-2017']",10678,TRUE,19,1
Can I manipulate Web pages from Xcode UI Testing?,"<p>I have my test cases written in Swift3 UI Testing in Xcode, my test cases run in an iOS application in simulator. One of our functionalities is bring assets into our app from dropbox, whenever we tap on dropbox icon (from our app) the dropbox web site opens to allow the user to LogIn. my question is, is there any way to use swift code that can automate the logIn on the web site? I would like to automate all that process.</p>
",https://stackoverflow.com/questions/42236059/can-i-manipulate-web-pages-from-xcode-ui-testing,"['xcode', 'xcode-ui-testing']",32,FALSE,0,1
VS 2012 Coded UI Testing and WPF User Control,"<p>I have an application that uses a UserControl inside of a Window, Coded UI Testing recognizes everything in the Window (buttons, etc.) but inside the UserControl I just get a blue box around the area and cannot select anything inside for recording. </p>

<p>I've been all over google for this issue and I think it has to do with the AutomationPeers (?). Any suggestions would be useful in how to get these elements visible to Coded UI</p>
",https://stackoverflow.com/questions/41579433/vs-2012-coded-ui-testing-and-wpf-user-control,"['wpf', 'visual-studio-2012', 'coded-ui-tests']",205,FALSE,0,2
iOS UI Testing: Cant Access elements - not in Elementtree,"<p>Im am new to iOS UI Testing, and ive encountered a Problem.</p>

<p>I have a Cell in a TableView that expands on click. But i can not access any of the elements that were expanded. I Printed out the elementtree and noticed that they are not contained in the tree:</p>

<pre><code>Table 0x608000379a40: traits: 35192962023424, {{0.0, 290.0}, {320.0, 234.0}}
                        Cell 0x608000379b00: traits: 8589934592, {{0.0, 290.0}, {320.0, 85.5}}
                          StaticText 0x608000379bc0: traits: 8589934656, {{93.0, 298.0}, {186.0, 16.0}}, label: 'Test Preview'
                          StaticText 0x608000379c80: traits: 8589934656, {{93.0, 316.0}, {186.0, 16.0}}, label: '1234'
                          StaticText 0x608000379d40: traits: 8589934656, {{93.0, 334.0}, {186.0, 16.0}}, label: 'grün'
                          Button 0x608000379e00: traits: 8589934593, {{93.0, 350.0}, {186.0, 25.0}}, label: 'bottomArrow'
                          Button 0x608000379ec0: traits: 8589934593, {{287.0, 290.0}, {33.0, 85.0}}, label: 'emptyStar'
</code></pre>

<p>The elements listed here, are the ones that are already visible when the cell is collapsed. When expanding the cell, i simply unhide the prevoiusly hidden elements. </p>

<p>This is my cell when it is <a href=""https://i.stack.imgur.com/ACyl3.png"" rel=""nofollow noreferrer"">collapsed</a>
This is my cell when it is <a href=""https://i.stack.imgur.com/xkhZB.png"" rel=""nofollow noreferrer"">expanded</a></p>

<p>Whats the problem here? Why are the elements accessible for me? 
(I did use a sleep(10) before printing out the elementtree to make sure that its not a timing issue)</p>

<p><strong>EDIT</strong>
I figured out, that the problem is hiding and unhiding the views, not adding the views dynamically. If i unHide a view programmatically, it is NOT in my elementtree, but when i have it unHidden in the first place, it is there as it should...</p>
",https://stackoverflow.com/questions/45876185/ios-ui-testing-cant-access-elements-not-in-elementtree,"['ios', 'swift', 'uitableview', 'testing']",240,FALSE,0,1
Dramatically slow Web UI testing on real iOS device,"<p>We have set of mobile UI test for website written with Java, using Selenide, Cucumber, Chromedriver. All these test running fast on chrome browser emulator. Now I'm trying to run all my tests on real iOS device, using:</p>

<pre><code>Appium 1.6.3;
ios_webkit_debug_proxy 1.7.1 (Built with libimobiledevice v1.2.0, libplist v1.12);
Xcode 8.2.1 (8C1002);
WebDriverAgent;
iPhone 5s (two real devices - iOS v9.2.1 and iOS v10.2.1);
MacOS Sierra 10.12.3
</code></pre>

<p>Test successfully passes, but it is dramatically slow. For comparison, one small scenario take <strong>3 min 20 sec on real device, and 20 seconds on chrome emulator</strong>.</p>

<p>Is it possible to optimize work of ios_webkit_debug_proxy, appium or WebDriverAgent? </p>

<p>Looks like <em>ios_webkit_debug_proxy</em> makes some heap dumps during test run and this makes test slow. Am I correct? Is it possible to run tests against real iOS device without <em>ios_webkit_debug_proxy</em>?</p>

<p>Please, help me with this.</p>
",https://stackoverflow.com/questions/42486684/dramatically-slow-web-ui-testing-on-real-ios-device,"['webdriver', 'appium', 'xcode-ui-testing']",712,TRUE,0,1
Launching iOS App in UI Testing Mode from Windows 10,"<p>It is obvious that we can run iOS App (.ipa, .app) in UITest mode from MacOSX using Xcode or Xcode command line tools. </p>

<p>But I saw some test-automation tools, who can launch App in UITesting mode (Appium Studio, QUAmotion, Ranorex, ..etc) from Windows 10. They are even giving back elements. (which is possible only in UITestMode)</p>

<p>As per my knowledge, UI Testing mode is only supported on MacOSX with Xcode because Xcode has a testManager which it uses to manage the Testcases while running. As for iOS Device attached to windows. LibiMobileDevice with the help of itunes gives functionalities like installing, running, uninstalling etc.</p>

<p>Can any one explain or help me with some library (paid or free )that can help me in Launching iOS app with UI Testing mode on iOS Device from Windows 10 ?</p>
",https://stackoverflow.com/questions/45714896/launching-ios-app-in-ui-testing-mode-from-windows-10,"['ios', 'iphone', 'windows', 'uitest', 'launching']",664,FALSE,2,1
Come back to activity from maps intent espresso - UI testing,"<p>I am using Espresso for UI testing. I wanna test a feature that Intent the app to the google maps app and come back to the same activity. The Intent is done successfully and the google maps is opened but i dont have control over the maps app and <code>Espresso.pressBack();</code>  is not working. Is there a way to press back button using espresso ?</p>
",https://stackoverflow.com/questions/45753946/come-back-to-activity-from-maps-intent-espresso-ui-testing,"['android', 'google-maps', 'android-intent', 'ui-automation', 'android-espresso']",770,FALSE,1,1
How to close an NSWindow during UI Testing with Xcode?,"<p>I am developing a document based Application for macOS. How can I close an existing NSWindow at the beginning of a test case?</p>
",https://stackoverflow.com/questions/44355770/how-to-close-an-nswindow-during-ui-testing-with-xcode,"['macos', 'xcode-ui-testing']",96,FALSE,0,1
How to implement Jake Wharton&#39;s robot pattern to Espresso UI testing?,"<p>Jake Wharton delivered a fascinating talk where he proposes some smart ways to improve our UI tests by abstracting the detail of how we perform UI out of the tests: <a href=""https://news.realm.io/news/kau-jake-wharton-testing-robots/"" rel=""noreferrer"">https://news.realm.io/news/kau-jake-wharton-testing-robots/</a></p>

<p>An example he gives is a test that looks as follows, where the PaymentRobot object contains the detail of how the payment amount &amp; recipient are entered into the UI. Putting that one place makes a lot of sense so when the UI inevitably changes (e.g. renaming a field ID, or switching from a TextEdit to a TextInputLayout), it only needs updating in one place not a whole series of tests. It also makes the tests much more terse and readable. He proposes using Kotlin to make them even terser. I do not use Kotlin but still want to benefit from this approach.</p>

<pre><code>@Test public void singleFundingSourceSuccess {
    PaymentRobot payment = new PaymentRobot();
    ResultRobot result = payment
        .amount(42_00)
        .recipient(""foo@bar.com"")
        .send();
    result.isSuccess();
}
</code></pre>

<p>He provides an outline of how the Robot class may be structured, with an explicit isSuccess() response, returning another Robot which is either the next screen, or the state of the current one:</p>

<pre><code>class PaymentRobot {
    PaymentRobot amount(long amount) { ... }
    PaymentRobot recipient(String recipient) { .. }
    ResultRobot send() { ... }
}

class ResultRobot { 
    ResultRobot isSuccess() { ... }
}
</code></pre>

<p>My questions are:</p>

<ul>
<li>How does the Robot interface with the Activity/Fragment, and specifically where is it instantiated? I would expect that happens in the test by the runner, but his examples seem to suggest otherwise. The approach looks like it could be very useful, but I do not see how to implement it in practice, either for a single Activity/Fragment, or for a sequence of them.</li>
<li>How can this approach be extended so that the isSuccess() method can handle various scenarios. e.g. if we're testing a Login screen, how can isSuccess() handle various expected results like: authentication success, API network failure, and auth failed (e.g. 403 server response)? Ideally the API would be mocked behind Retrofit, and each result tested with an end to end UI test.</li>
</ul>

<p>I've not been able to find any examples of implementation beyond Jake's overview talk.</p>
",https://stackoverflow.com/questions/43847448/how-to-implement-jake-whartons-robot-pattern-to-espresso-ui-testing,"['android', 'android-espresso', 'android-testing']",2372,TRUE,6,2
how can i record in Xcode 9 (for UI testing),"<p>I can't find the record button in Xcode 8 (for UI testing, I didn't find any help online [it's not in the debug bar]).</p>

<p>where is it or how can I record?</p>
",https://stackoverflow.com/questions/45170222/how-can-i-record-in-xcode-9-for-ui-testing,"['xcode', 'xctest']",1713,FALSE,0,1
"Coded UI testing, swapping tabs and unable to find controls","<p>I have a c# coded UI script, that opens a page, enters a value into a field, clicks an image, clicks a link to open another page in a new tab, enters some data, switches back to the first tab, enters more data BUT cannot find the button 2nd time around.</p>

<pre><code>var browser = BrowserWindow.Launch(""...url..."");
var edit = new HtmlEdit(browser);
edit.SearchProperties.Add(HtmlEdit.PropertyNames.Id, ""name"");
edit.Text = ""Bob"";
var img = new HtmlImage(browser);
img.SearchProperties.Add(HtmlImage.PropertyNames.Id, ""requestImg"");
Mouse.Click(img);
var link = new HtmlHyperlink(browser);
link.SearchProperties.Add(HtmlHyperlink.PropertyNames.InnerText, ""newTab"");
Mouse.Click(link);
var place= new HtmlEdit(browser);
place.SearchProperties.Add(HtmlEdit.PropertyNames.Id, ""place"");
place.Text = ""Here"";
Keyboard.SendKeys(""^{Tab}"");
edit = new HtmlEdit(browser);
edit.SearchProperties.Add(HtmlEdit.PropertyNames.Id, ""name"");
edit.Text = ""Sue"";
img = new HtmlImage(browser);
img.SearchProperties.Add(HtmlImage.PropertyNames.Id, ""requestImg"");
Mouse.Click(img);
Playback.Wait(12000);
... do more stuff
</code></pre>

<p>Everything works as expected, except that last attempt to click on the image. There are no error messages/exceptions from the last attempt to click on the image, and the subsequent code runs, but fails as the click event has not worked.
Why would the code that changes text boxes work after tabbing back, but not the clicking on the image tab? I've tried adding in browser.Find(), browser.Refresh(), img.Find() - none improve the situation</p>
",https://stackoverflow.com/questions/45434396/coded-ui-testing-swapping-tabs-and-unable-to-find-controls,"['c#', 'coded-ui-tests']",468,FALSE,0,1
Need Visual Studio Toolbar Button To Start Coded UI Testing,"<p>I want to add a button to my Visual Studio toolbar that will start debugging the Coded UI test that I have in the Visual Studio code window, and another button that will run the test I have there (""Run"" and ""Debug"" options). I've been looking for this off and on for two years in VS2012, 2013, and 2015.</p>

<p>Does anyone know where to find these commands in the ""Add/Remove Buttons => Customize => Toolbar => Add Command"" dialog? Or maybe somewhere else along with how to implement them in a V.S. toolbar?</p>

<p>I have been customizing Visual Studio toolbars since VS2005. I like having buttons that do things quickly (e.g. in a single click). Of course, I know how to right-click and select Debug or Run to start a test. The Debug and Run commands are positioned <em>somewhere</em> on that shortcut menu (a poor name in this case, since it contains a minimum of 32 items and sometimes more than 40), but they move around depending on what else is in the menu. I would prefer to have just one place to find the command. You know: Point-n-click.</p>

<p>For anyone who isn't familiar with Coded User Interface Testing (Coded UI), you can't just set a startup project. A Coded UI project generates a DLL, not an exe, so neither F5 nor the green "">"" will work in a Coded UI project.</p>

<p>Does anyone have any insight into this?</p>
",https://stackoverflow.com/questions/46553183/need-visual-studio-toolbar-button-to-start-coded-ui-testing,"['visual-studio-2015', 'toolbar', 'coded-ui-tests']",87,FALSE,0,0
XCTest UI Testing - How to close and open an app without relaunch?,"<p>I want to make my app to go to background, and then comeback to the foreground.</p>

<p>To make an app to go background: <code>XCUIDevice.shared().press(XCUIDeviceButton.home)</code></p>

<p>To terminate an app(force tap): <code>XCUIApplication().terminate()</code></p>

<p>To launch the app: <code>XCUIApplication().launch()</code></p>

<p><strong>Problem</strong>: when I try to close and open the app, the launch() method clears the app from background and it opens the app freshly. </p>

<p>I saw this <a href=""https://stackoverflow.com/a/33653297/1389515"">comment</a> regarding this. But cant able to figure out it in UI test. I'm using Swift. Help needed!!</p>
",https://stackoverflow.com/questions/41951539/xctest-ui-testing-how-to-close-and-open-an-app-without-relaunch,"['background', 'xctest', 'launch', 'xcode-ui-testing', 'suspend']",9851,TRUE,11,4
Xcode UI Testing not failing even though app crashes with SIGABRT,"<p>After the iOS 11 upgrade I found a crash in my application related to the share sheet and saving an image due to the newly added permission checks. That is all good, easy fix. However, I wanted to write a UI automation test to check for this type of thing in the future since I've been burned twice now.</p>

<p>So I wrote the test and it crashes as expected when i run through Xcode, however when I hit continue on the debugger (after the SIGABRT) the test says it completes successfully and is not reporting a failure. </p>

<p>Tried googling but can't find anything relevant, anyone know why the test would say passed when the app crashes? </p>

<p>Here is a code snippet from test, it selects the option appropriately and then SIGABRT, Xcode catches it and when i hit continue the test says it passes. If I put more items after the line causing the crash the test just spins indefinitely.</p>

<pre><code>    let shareButton = app.tables.tables.buttons[""share""]
    shareButton.tap()

    let shareSheet = app.sheets[""Share Sheet Title""]
    shareSheet.buttons[""Item to Share""].tap()
    app.collectionViews.collectionViews.buttons[""Save Image""].tap()
</code></pre>

<p>Thanks</p>
",https://stackoverflow.com/questions/47167399/xcode-ui-testing-not-failing-even-though-app-crashes-with-sigabrt,"['swift', 'xcode', 'xctest', 'xcode-ui-testing']",366,FALSE,4,0
UI testing - No matches found for Descendants matching type... recording generated code,"<p>I am getting an error </p>

<p><code>No matches found for Find: Descendants matching type NavigationBar from input {(
    Application, 0x60400019b790, pid: 20515, label: '&lt;appname&gt;'
)}</code></p>

<p>but the code was generated by the recording function of XCUITest so I don't understand why it can't find the navbar. I have added an <code>accessibilityIdentifier</code> that is a localized string called <code>dashboardNavBar</code> to try and use that to find it instead but I am having trouble querying it. The current code I am using is: </p>

<pre><code>func testLoginLogout() {
    let app = XCUIApplication()
    //login credentials and other code that takes me to dashboard of app
    app.navigationBars[""Dashboard""].children(matching: .button).element(boundBy: 2).tap()
    app.sheets[""Do you want to Logout ?""].buttons[""OK""].tap()
}
</code></pre>

<p>and the <code>app.navigationBars...</code> line is the line that throws the error above. I was hoping someone could tell me why it is unable to locate this navBar or whatever the problem is, and how I can fix it or work around it using the <code>accessibilityIdentifier</code>. Thanks.</p>
",https://stackoverflow.com/questions/47580331/ui-testing-no-matches-found-for-descendants-matching-type-recording-generat,"['ios', 'swift', 'xctest', 'xcuitest']",10775,TRUE,9,2
UI testing fails with error &quot;Failed to get snapshot within 15.0s&quot;,"<p>I am having a table view with a huge amount of cells. I tried to tap a particular cell from this table view. But the test ending with this error:</p>
<blockquote>
<p>Failed to get snapshot within 15.0s</p>
</blockquote>
<p>I assume that, the system will take snapshot of the whole table view before accessing its element. Because of the huge number of cells, the snapshot taken time was not enough (15 secs is may be the system default time).</p>
<p>I manually set the sleep time / <a href=""https://stackoverflow.com/a/42118692/1389515"">wait time</a> (I put 60 secs). Still I can not access the cells after 60 seconds!!</p>
<p>A strange thing I found is, before accessing the cell, I print the object in Debugger like this:</p>
<pre><code>po print XCUIApplication().cells.debugDescription
</code></pre>
<p>It shows an error like</p>
<blockquote>
<p>Failed to get snapshot within 15.0s</p>
<p>error: Execution was interrupted, reason: internal ObjC exception breakpoint(-3)..</p>
<p>The process has been returned to the state before expression evaluation.</p>
</blockquote>
<p>Again if I print the same object using</p>
<pre><code>po print XCUIApplication().cells.debugDescription
</code></pre>
<p>Now it will print all cells in the tableview in Debugger view.</p>
<p>No idea about why this happens. Does anyone faced similar kind of issues? Help needed!!</p>
",https://stackoverflow.com/questions/44429118/ui-testing-fails-with-error-failed-to-get-snapshot-within-15-0s,"['error-handling', 'xctest', 'snapshot', 'xcode-ui-testing']",4132,TRUE,2,1
Fro the map view zoom out in UI testing not working,"<p>For the UI Test case I need to ""zoom out"" in the map view. When using pinch zoom out code it only moves map to the left.</p>

<pre><code>let app = XCUIApplication()
app.maps.element.pinch(withScale: 0.9, velocity: -0.5)
</code></pre>

<p>Dose someone knows how to achieve ""zoom out"" functionality in the UI Testing?</p>

<p>I want to notice that ""zoom in"" works fine.</p>
",https://stackoverflow.com/questions/45077214/fro-the-map-view-zoom-out-in-ui-testing-not-working,"['ios', 'swift', 'xcode-ui-testing']",885,TRUE,1,1
AWS DEVICE FARM - iOS - UI Testing Failure - Failure getting snapshot Error,"<p>When I run tests locally or on Circle CI they work 100% of the time. On AWS they fail 95% of the time with this error, not a test fail. I have tried manually and with fastlane, same result. I have also removed everything from the tests. If any piece of UI is interacted with it causes this failure. If test is empty it will succeed.  Anyone have a solution? Thanks</p>

<p>UI Testing Failure - Failure getting snapshot Error Domain=XCTestManagerErrorDomain Code=9 ""Error getting main window -25204"" UserInfo={NSLocalizedDescription=Error getting main window -25204}</p>
",https://stackoverflow.com/questions/41831633/aws-device-farm-ios-ui-testing-failure-failure-getting-snapshot-error,"['ios', 'xcode-ui-testing', 'aws-device-farm']",649,FALSE,1,0
Visual Studio 2015.2 with Xamarin for Mobile app automation (UI) testing,"<p>I got a new project to work on mobile automation testing. I have no experience with mobile and I have just started to look into Xamarin plug in with Visual Studio 2015.</p>

<p>It looks pretty good plug in / extension to work with Visual Studio. I have seen below video on how to use Xamarin Test Recorder with Visual Studio.
<a href=""https://channel9.msdn.com/Events/Visual-Studio/Visual-Studio-2017-Launch/APP-103"" rel=""nofollow noreferrer"">https://channel9.msdn.com/Events/Visual-Studio/Visual-Studio-2017-Launch/APP-103</a>
<a href=""https://channel9.msdn.com/Shows/XamarinShow/User-Interface-Automation-with-Charles-Wang"" rel=""nofollow noreferrer"">https://channel9.msdn.com/Shows/XamarinShow/User-Interface-Automation-with-Charles-Wang</a></p>

<p>Videos are pretty clear on how to do automation testing and I could do the same. However the blockage I have is no where I am able to see how the great UI interface (emulator / simulator) came into picture. Where to get it ? which one to use ?</p>

<p>To reach the point of the recording or writing my code for UI Automation, I need to understand all the pre requisites and how to get the emulator and other stuffs.</p>

<p>Could some one please share details on above points.</p>

<p>Thanks in advance.</p>

<p>Best Regards,
Ahetejazahmad Khan.</p>
",https://stackoverflow.com/questions/47525912/visual-studio-2015-2-with-xamarin-for-mobile-app-automation-ui-testing,"['xamarin', 'visual-studio-2015', 'xamarin.ios', 'xamarin.forms', 'xamarin.android']",73,FALSE,1,0
Xcode UI testing can&#39;t be used to dismiss KeyChain access dialog,"<p>My application requires access to the KeyChain when first started. Therefore, whenever new build is launched, a system dialog pops up asking permissions from the user for my application to access the KeyChain. This, however, blocks UI testing completely - the <code>XCUIApplication</code>'s <code>launch</code> call is synchronous, so there is no way to dismiss this dialog programmatically.</p>

<p>How can I workaround this problem? </p>
",https://stackoverflow.com/questions/41754562/xcode-ui-testing-cant-be-used-to-dismiss-keychain-access-dialog,"['objective-c', 'macos', 'xcode-ui-testing']",149,FALSE,0,0
how to test windows 10 store apps using coded UI testing?,"<p><a href=""https://i.stack.imgur.com/RCIAp.png%5C"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/RCIAp.png%5C"" alt=""trying to use Xaml.launch(automation id for the app)""></a></p>

<p>trying to launch an app from a coded ui testing project for windows app store.</p>
",https://stackoverflow.com/questions/41587508/how-to-test-windows-10-store-apps-using-coded-ui-testing,"['visual-studio-2013', 'coded-ui-tests']",523,TRUE,0,1
"Android UI testing, what is the alternative for deprecated ViewAsserts assertHorizontalCenterAligned?","<p>In Android UI testing we had the <a href=""https://developer.android.com/reference/android/test/ViewAsserts.html"" rel=""nofollow noreferrer"">ViewAsserts</a> class which is deprecated in API level 24.</p>

<p>The class had some methods such as <a href=""https://developer.android.com/reference/android/test/ViewAsserts.html#assertHorizontalCenterAligned(android.view.View,%20android.view.View)"" rel=""nofollow noreferrer"">assertHorizontalCenterAligned</a> to test if a view is horizontally centered within another view.</p>

<p>What is the alternative for such a method in the new Espresso <a href=""https://developer.android.com/reference/android/support/test/espresso/assertion/PositionAssertions.html"" rel=""nofollow noreferrer"">PositionAssertions</a>? </p>

<p>It has Assertions for left,right,top and bottom alignment, but no center assertions.</p>
",https://stackoverflow.com/questions/42342395/android-ui-testing-what-is-the-alternative-for-deprecated-viewasserts-asserthor,"['android', 'android-espresso', 'android-testing']",192,TRUE,0,1
"In iOS UI Testing, how do I identify the MKUserLocation annotation?","<p>I'm struggling to identify how I can tell that the MKMapView is showing the current user location pin in a UI Test.  This is a MKUserLocation annotation (and I've created an MKAnnotationView to use an image for the pin instead of the blue spot.) </p>

<p>Debugging tells me that the MKUserLocation annotation instance has a title of ""My Location"".  I was expecting that the following would work:</p>

<pre><code>app.maps.element.otherElements[""My Location""]
</code></pre>

<p>would return it but [that code].exists returns false.  Printing debugDescription of otherElements lists a whole set of annotations on the map but not the User Location.</p>

<p>Is there a different type of XCUIElement that represents the pin/annotation/annotation view that I can check for?</p>
",https://stackoverflow.com/questions/46759246/in-ios-ui-testing-how-do-i-identify-the-mkuserlocation-annotation,"['ios', 'mkannotation', 'mkannotationview', 'uitest', 'mkuserlocation']",917,TRUE,0,1
UI Testing (casperjs) with good known status of data (mysql database),"<p>I'm using <a href=""http://casperjs.org/"" rel=""nofollow noreferrer"">CasperJS</a> for automated UI tests. I've done the basic UI testing and validation with some random data, kind of POC. I've set up this automation using bash script which kicks to start the web server, load MySQL data from SQL file, start CasperJS test cases, stop the web server, check the log files.</p>

<p>Now, I want to start the testing with some good known status of data which are stored in MySQL. So that I can test the list data and form data with detailed field information with some known database status. How should I know the status of data in the database at a moment?</p>

<p>1) Should I use pre-populated JSON dumped file which has status and details about all data?</p>

<p>2) Should I use web service API? (web service APIs are being used to show/save/delete data from the web page)</p>

<p>Let's take an example. I've 5 users in <code>Users</code> table. Now when I open the home page it shows 5 users with some rough details. When I click on any record from the list of users, it shows a form with detailed information about that user. The webpage is requesting to the web application to get the detail about a user with the help of user_id to show the detailed user data in a form. Now I want to check that all the data in that form is populated correctly. So at the next step, what would be the preferred way, should I read content from JSON dumped file or should I use web service API (like webpage does).</p>

<p>Searching this problem online, I also found <a href=""https://labs.mysql.com/"" rel=""nofollow noreferrer"">MYSQL HTTP plugin</a>. Should I consider this as well? and How safe it is to use? (I know from the docs that this plugin is not for the production, it is just for testing purpose only. :) )</p>
",https://stackoverflow.com/questions/47631067/ui-testing-casperjs-with-good-known-status-of-data-mysql-database,"['mysql', 'json', 'bash', 'casperjs', 'ui-automation']",77,FALSE,0,1
C# Coded UI testing - enter text into a javascript window.prompt text box,"<p>I'm running coded UI tests in Visual Studio Enterprise 2017.</p>

<p>My webpage under test has a javascript popup asking for an e-mail address to be entered. I can locate the confirmationPopup (highlight is drawn correctly), and I can click buttons within it, such as the cancel. </p>

<pre><code>confirmationPopup = new WinWindow();
confirmationPopup.SearchProperties.Add(WinWindow.PropertyNames.ControlType, ""Dialog"");
confirmationPopup.SearchProperties.Add(WinWindow.PropertyNames.ClassName, ""#32770"");
confirmationPopup.TechnologyName = ""MSAA"";
confirmationPopup.Find();
confirmationPopup.DrawHighlight();

var cancelButton = new WinButton(confirmationPopup);
cancelButton.SearchProperties.Add(WinButton.PropertyNames.Name, ""Cancel"");
Mouse.Click(cancelButton);
</code></pre>

<p>What I am struggling to do is enter text in the popup's input box:</p>

<pre><code>var textInput = new WinEdit(confirmationPopup);
textInput.SearchProperties.Add(WinEdit.PropertyNames.ClassName, ""Edit"");
textInput.TechnologyName = ""MSAA"";
textInput.DrawHighlight();
textInput.Text = ""bill@microsoft.com"";
</code></pre>

<p>The highlight is drawn around the correct control, but the textInput.Text= line gives an error 
<strong><em>Additional information: SetProperty of ""Text"" is not supported on control type: Window</em></strong></p>

<p>Any ideas what I'm doing wrong?</p>
",https://stackoverflow.com/questions/45547420/c-coded-ui-testing-enter-text-into-a-javascript-window-prompt-text-box,"['c#', 'coded-ui-tests']",749,TRUE,3,1
Xcode UI testing collection view cells became non-hittable on iOS 11,"<p>We were using this code to simulate a tap on the first cell of a <code>UICollectionView</code> on Xcode UI Testing:</p>

<pre><code>XCUIElementQuery *query = [application descendantsMatchingType:XCUIElementTypeAny];
XCUIElement *collectionView = [query objectForKeyedSubscript:collectionViewAccessibilityIdentifier];
XCUIElement *targetCell = [lensesCollectionView.cells elementBoundByIndex:cellIndex];
if (targetCell.hittable) {
    [targetCell tap];
}
</code></pre>

<p>this works fine on iOS 10, but stopped working on iOS 11. The <code>targetCell</code> is never <code>hittable</code> no matter what. Adding a <code>sleep(10)</code> before <code>XCUIElement *targetCell = [lensesCollectionView.cells elementBoundByIndex:lensIndex]</code> doesn't help.</p>

<p>I've seen hacky solutions mentioned elsewhere such as </p>

<pre><code>func forceTapElement() {   
    if self.isHittable {   
        self.tap()   
    } else {   
        var coordinate: XCUICoordinate = self.coordinateWithNormalizedOffset(CGVectorMake(0.0, 0.0))   
        coordinate.tap()   
    }  
}
</code></pre>

<p>but that doesn't look very clean. What's the cleanest way of achieving this?</p>

<hr>

<p><em>Update</em>: If I try to tap it without checking for <code>hittable</code> I get this error:</p>

<blockquote>
  <p>error: Error -25204 performing AXAction 2003 on element  pid: 43616, elementOrHash.elementID: 4882574576.240</p>
</blockquote>
",https://stackoverflow.com/questions/46819807/xcode-ui-testing-collection-view-cells-became-non-hittable-on-ios-11,"['ios', 'xcode', 'ios11', 'xcode-ui-testing']",1651,TRUE,3,2
UI Testing with Xcode: How to find a button that has no title?,"<p>I have some buttons in my user interface that only display an image and no title. How can I access them during a UI Test?  <code>window.buttons[""delete""].click()</code> doesn't find the button due to lack of title. And I cannot set the title because the image has some transparency. </p>
",https://stackoverflow.com/questions/44356131/ui-testing-with-xcode-how-to-find-a-button-that-has-no-title,"['macos', 'xcode-ui-testing']",7476,TRUE,8,2
Access elements in a custom view component in Swift 3 UI testing,"<p>I'm a newbie to any type of iOS programming. I am trying to write UI test cases for one of my scenes.</p>

<p>Following is the code I'm getting when I use recode method and tap on the custom component. </p>

<pre><code>let button = XCUIApplication().children(matching: .window).element(boundBy: 0).children(matching: .other).element.children(matching: .button).element
</code></pre>

<p>In this custom component there are two buttons. I wanna know which button is selected. For that I need to identify the button. But i'm getting same code where ever I tap on the custom view.</p>

<p>How can I access each component inside custom view. Any help would be great.</p>
",https://stackoverflow.com/questions/43658903/access-elements-in-a-custom-view-component-in-swift-3-ui-testing,"['ios', 'iphone', 'unit-testing', 'swift3', 'xcode-ui-testing']",3471,TRUE,2,2
"Xcode 8: UI Testing, Neither element not any descendant has keyboard focus","<p>I've recently started to use UI testing within Xcode. I was able to record the test and play it back and it worked perfectly fine. I recently changed the accessibility labels for textFields to make the test look cleaner by giving it a better name.</p>

<p>However, now when I record the UI test and play it back again to test it, I get an error ""<strong><em>Neither element not any descendant has keyboard focus.</em></strong>"". I've attempted to uncheck hardware keyboard as mentioned in other posts, but that doesn't work for me.</p>

<pre><code>    //test login with username and empty password
    let app = XCUIApplication()
    let elementsQuery = app.scrollViews.otherElements
    let emailtextfieldElement = elementsQuery.otherElements[""emailTextField""]
    let passwordtextfieldElement = elementsQuery.otherElements[""passwordTextField""]

    emailtextfieldElement.tap()
    passwordtextfieldElement.tap()
    emailtextfieldElement.tap()
    app.typeText(""wayne@test.com"")
    passwordtextfieldElement.tap()
    app.buttons[""Login - signInButton""].tap()
</code></pre>

<p>Anybody know the fix for this?</p>
",https://stackoverflow.com/questions/45076386/xcode-8-ui-testing-neither-element-not-any-descendant-has-keyboard-focus,"['swift', 'xcode', 'xcode8', 'xcode-ui-testing']",1161,FALSE,2,1
UI Testing: Slider fails to adjust when nested in Table View Cell,"<p>In UI Testing on Xcode 9.0 (9A235), interacting with <code>UISlider</code>with <code>adjust(toNormalizedSliderPosition:)</code> does not work at all when <code>UISlider</code>is nested in a <code>UITableViewCell</code>.</p>

<p>I have tested in many different scenarios:
- Normal <code>UISlider</code>s not embedded in a <code>UITableView</code> work fine with the <code>adjust</code> method.
- <code>UISlider</code> that co-exists with a <code>UITableView</code> but not inside a Table View Cell continues to work with <code>adjust</code>
- <code>UISlider</code> in a <code>UITableView</code> can be uniquely identified.
- <code>UISlider</code> identified in a <code>UITableView</code> can respond to simple event like <code>tap()</code>
- <code>UISlider</code> identified in a <code>UITableView</code> doesn't work with <code>adjust</code> method at all, even when I modify the number of rows to 1. The error message is:</p>

<blockquote>
  <p>Failure fetching attributes for element   pid: 24415,
  elementOrHash.elementID: 106102876671744.43: Error
  Domain=XCTDaemonErrorDomain Code=13 ""Fetching value for attribute 5011
  returned AX error -25205."" UserInfo={NSLocalizedDescription=Fetching
  value for attribute 5011 returned AX error -25205.}</p>
</blockquote>

<p>Related discussion I found online:
<a href=""https://forums.developer.apple.com/thread/77445"" rel=""nofollow noreferrer"">https://forums.developer.apple.com/thread/77445</a></p>

<p>I have uploaded <a href=""https://github.com/pt2277/XCTest_UITest_UISlider"" rel=""nofollow noreferrer"">my code online</a> too if anyone is interested in looking at it.</p>

<p>I have already submitted a <a href=""http://www.openradar.me/radar?id=5059599031861248"" rel=""nofollow noreferrer"">bug report</a> to Apple regarding this. What I am asking is, does anyone know of a possible workaround I can use to adjust the <code>UISlider</code> values when the slider is nested in a <code>UITableViewCell</code>? Thanks!</p>
",https://stackoverflow.com/questions/46785790/ui-testing-slider-fails-to-adjust-when-nested-in-table-view-cell,"['ios', 'swift', 'tableview', 'uislider', 'xcode-ui-testing']",895,TRUE,2,1
XCtest UI testing - running test stalls on wait for app to idle,"<p>I'm have just starting using <strong>XCTest</strong> for UI testing.<br>
While running my tests, execution takes forever.</p>

<p>I get following output:</p>

<pre><code>Wait for app to idle - waits 120 seconds to fail
    App animations complete notification not received, will attempt to continue.
</code></pre>

<p>I have looked all over and found zero answer on how to either change the timeout or how to manipulate the app to move on.</p>

<p>There are no animations running at all in the app.  The screen is fully loaded.  My developers also have zero answers as well and I have tried disabling animations which fails the tests outright.  </p>

<p>Any ideas on how I can address this?  </p>

<pre><code> func testHomeScreen() {
        logIn()

        let home = app.navigationBars[""HOME""].staticTexts[""HOME""]
        waitForElementToAppear(element: home)
        XCTAssert(home.exists)

        let myFriendsButton = app.buttons[""My Friends""]
        XCTAssert(myFriendsButton.exists)

        let collectionViewsQuery = app.collectionViews
        collectionViewsQuery.buttons[""compose""].tap()
        app.navigationBars[""CREATE POST""].buttons[""CANCEL""].tap()
        collectionViewsQuery.buttons[""photo""].tap()
        app.navigationBars[""PHOTO BOOTH""].buttons[""CANCEL""].tap()

        let element = collectionViewsQuery.children(matching: .cell).element(boundBy: 1).children(matching: .other).element
        element.children(matching: .other).element(boundBy: 0).children(matching: .image).element(boundBy: 0).tap()

        let profileCloseButton = app.buttons[""profile close""]
        profileCloseButton.tap()

        let image = element.children(matching: .image).element
        image.swipeUp()

        let button = app.navigationBars[""DETAILS""].buttons["" ""]

        let cell = collectionViewsQuery.children(matching: .cell).element(boundBy: 0)
        cell.buttons[""actionsheet""].tap()
        app.sheets.buttons[""Cancel""].tap()
        cell.buttons[""comment""].tap()
        button.tap()
        collectionViewsQuery.buttons[""like selected""].tap()
</code></pre>

<p>Here is my LogIn func and Setup. </p>

<p>func logIn() {
    let app = XCUIApplication()</p>

<pre><code>if  app.tabBars.buttons[""HOME""].exists {
    logOut()
}
let logInButton = app.buttons[""LOG IN""]
logInButton.tap()

let elementsQuery = app.scrollViews.otherElements
let emailField = elementsQuery.textFields[""example@email.com""]
emailField.tap()
emailField.typeText(""***************"")

let passwordSecureTextField = elementsQuery.secureTextFields[""Password""]
passwordSecureTextField.tap()
passwordSecureTextField.typeText(""************"")

app.navigationBars[""LOG IN""].buttons[""btn login""].tap()

if app.staticTexts[""PLEASE TURN ON NOTIFICATIONS""].exists {
    XCTAssert(app.staticTexts[""This way you will be able to see when your friends post, message, like or comment on your stuff!""].exists)
    app.buttons[""NOT NOW""].tap()

}

if app.collectionViews.staticTexts[""3D Rooms Now Available!""].exists {
    XCTAssert(app.collectionViews.staticTexts[""Chat with friends in 3D rooms wherever you go! Tap here to get started""].exists)
    app.collectionViews.buttons[""close""].tap()
}


if app.staticTexts[""DAILY""].exists {
    XCTAssert(app.staticTexts["" SPIN""].exists)
    app.buttons[""close""].tap()
}
</code></pre>

<p>}</p>

<p>Setup:</p>

<p>class HomeScreenTests: XCTestCase {
    let app = XCUIApplication()</p>

<pre><code>override func setUp() {
    super.setUp()

    // Put setup code here. This method is called before the invocation of each test method in the class.

    // In UI tests it is usually best to stop immediately when a failure occurs.
    continueAfterFailure = false
    // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method.
    app.launch()


    // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this.
}
</code></pre>

<p>Here is a chunk of the output from the test logs:</p>

<p><a href=""https://i.stack.imgur.com/sVLjI.png"" rel=""nofollow noreferrer"">LogFile</a></p>
",https://stackoverflow.com/questions/42798090/xctest-ui-testing-running-test-stalls-on-wait-for-app-to-idle,"['xctest', 'xcode-ui-testing']",1530,FALSE,0,0
How can I use table&#39;s view bottom refresh twice on UI Testing?,"<p>I had a problem that I use bottom refresh from table view, but only the first time works correctly. After the refreshing the table my test is freezing. There's my code:</p>

<pre><code>func test_lista(){

    //Entrar a la lista de ofertas
    app.tables.element(boundBy: 0).cells.element(boundBy: 2).tap()
    sleep(2)

    //Arrastrar la ultima fila
    app.swipeUp()
    app.swipeUp()
    let cell = app.tables.element(boundBy: 0).cells.element(boundBy: 2)
    let start = cell.coordinate(withNormalizedOffset: CGVector(dx: 0,dy: 0))
    let finish = cell.coordinate(withNormalizedOffset: CGVector(dx: 0,dy: -30.0))
    start.press(forDuration: 0, thenDragTo: finish)

    app.swipeUp()
    app.swipeUp()
    let cell2 = app.tables.element(boundBy: 0).cells.element(boundBy: 4)
    let start2 = cell2.coordinate(withNormalizedOffset: CGVector(dx: 0,dy: 0))
    let finish2 = cell2.coordinate(withNormalizedOffset: CGVector(dx: 0,dy: -30.0))
    start2.press(forDuration: 0, thenDragTo: finish2)

}
</code></pre>

<p>What am I doing wrong?</p>
",https://stackoverflow.com/questions/45816815/how-can-i-use-tables-view-bottom-refresh-twice-on-ui-testing,"['ios', 'xcode-ui-testing', 'ui-testing']",61,TRUE,0,1
Parallel UI-Testing with EarlGrey on Xcode 9 - PhaseScriptExecution [CP]\ Embed\ Pods error,"<p>I am trying to run parallel UI tests using the <a href=""https://github.com/google/EarlGrey"" rel=""nofollow noreferrer"">EarlGrey</a> framework(runs as a unit test target) following this <a href=""https://www.linkedin.com/pulse/parallel-ui-testing-using-xcode-9-beta-rushi-bhatt/"" rel=""nofollow noreferrer"">tutorial</a>. I managed to have success when running an XCTest UI target and an EarlGrey test target but i get the following errors when adding another earlgrey test target or when just running two earlgrey test targets at the same time.</p>

<p>The apple script im using is as follows: </p>

<pre><code>tell application ""iTerm""
    set myterm to create window with default profile
    tell myterm
        activate current session
        launch session ""Default Session""
        tell the current session
            write text ""cd ~/Desktop/tddSplitter/Splitter""
            write text ""xcodebuild clean -workspace Splitter.xcworkspace -scheme EarlGreyWelcomeScreenTests -sdk iphonesimulator11.0 -destination 'platform=iOS Simulator,id=476E9E8C-8248-4EF6-8054-67900D603E83'  test | xcpretty"" without newline
            tell (split vertically with same profile)
                write text ""cd ~/Desktop/tddSplitter/Splitter""
                write text ""xcodebuild clean -workspace Splitter.xcworkspace -scheme EarlGreyMyBillsTests -sdk iphonesimulator11.0 -destination 'platform=iOS Simulator,id=F3DEA448-147B-4DDB-AD83-16D18BA1A87F' test | xcpretty"" without newline
            end tell
            tell (split vertically with same profile)
                write text ""cd ~/Desktop/tddSplitter/Splitter""
                write text ""xcodebuild clean -workspace Splitter.xcworkspace -scheme EarlGreyNewBillTests -sdk iphonesimulator11.0 -destination 'platform=iOS Simulator,id=9129B18A-BC9A-452C-BA38-B968ED73B9EC' test | xcpretty"" without newline
            end tell
        end tell
        write (sessions of current tab) text linefeed
    end tell
end tell
</code></pre>

<p>The error i get at the bottom of each window fot each test target is the same and as follows:</p>

<pre><code>The following build commands failed:
PhaseScriptExecution [CP]\ Embed\ Pods\ Frameworks /Users/waynerumble/Library/Developer/Xcode/DerivedData/Splitter-dujnwkiaikdyiiczdwxhjrusebvf/Build/Intermediates.noindex/Splitter.build/Debug-iphonesimulator/Splitter.build/Script-84DCB13FCAD79943430C6362.sh
</code></pre>

<p>But above these errors can be other errors, so the last time i ran the script i got the following errors:</p>

<p>For EarlGreyWelcomeScreenTests target:</p>

<pre><code>Testing failed:
/Users/waynerumble/Library/Developer/Xcode/DerivedData/Splitter-dujnwkiaikdyiiczdwxhjrusebvf/Build/Products/Debug-iphonesimulator/Splitter.app/Frameworks/GTMSessionFetcher.framework: No such file or directory
</code></pre>

<p>For EarlGreyMyBillsTests target:</p>

<pre><code>Testing failed:
/Users/waynerumble/Library/Developer/Xcode/DerivedData/Splitter-dujnwkiaikdyiiczdwxhjrusebvf/Build/Products/Debug-iphonesimulator/Splitter.app/Frameworks/GTMSessionFetcher.framework: No such file or directory
error: couldn't remove '/Users/waynerumble/Library/Developer/Xcode/DerivedData/Splitter-dujnwkiaikdyiiczdwxhjrusebvf/Build/Products/Debug-iphonesimulator/Splitter.app/Frameworks/GTMSessionFetcher.framework' after command failed: No such file or directory
</code></pre>

<p>For EarlGreyNewBillTests target:</p>

<pre><code>Testing failed:
Command builtin-rm failed with exit code 513
Command /bin/sh failed with exit code 1
</code></pre>

<p>The only other information i think may help is my Podfile which is as follows:</p>

<pre><code># Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'

target 'Splitter' do
  # Comment the next line if you're not using Swift and don't want to use dynamic frameworks
    use_frameworks!
    inhibit_all_warnings!

    def allPods
      pod 'Firebase'
      pod 'Firebase/Database'
      pod 'Firebase/Auth'
      pod 'Firebase/Storage'
      pod 'LifetimeTracker'
      pod 'iCarousel'
    end

    def earlGreyUITests
      project 'Splitter'
      use_frameworks!
      inherit! :search_paths
      pod 'EarlGrey'
    end

    # Pods for Splitter

    allPods

    target 'UnitTests' do
      inherit! :search_paths
      allPods
    end

    target 'EarlGreyWelcomeScreenTests' do
      earlGreyUITests
      allPods
    end

    target 'EarlGreyMyBillsTests' do
      earlGreyUITests
      allPods
    end

    target 'EarlGreyNewBillTests' do
      earlGreyUITests
      allPods
    end

    post_install do |installer|
        installer.pods_project.targets.each do |target|
            target.build_configurations.each do |config|
                config.build_settings['EXPANDED_CODE_SIGN_IDENTITY'] = """"
                config.build_settings['ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES'] = ""NO""
                config.build_settings['CODE_SIGNING_REQUIRED'] = ""NO""
                config.build_settings['CODE_SIGNING_ALLOWED'] = ""NO""
            end
        end
    end
end
</code></pre>

<p>Any help or insight would be great as ive been striggling with this for a while and cant seem to get further than this with any new or consistent errors. Thanks</p>
",https://stackoverflow.com/questions/46604636/parallel-ui-testing-with-earlgrey-on-xcode-9-phasescriptexecution-cp-embed,"['ios', 'xcode', 'cocoapods', 'xcode-ui-testing', 'xcode9']",1024,FALSE,4,0
Run Automation UI Testing through Selenium and Coded UI Without Build from TFS,"<p>Our web application codes are stored on SVN instead with TFS. We are trying to set up our automated UI testing.</p>

<p>These are following tools our team are considered to use.
 - Microsoft Test Manager (Create Test cases associate with User stories)
 - Coded UI (Connect to TFS and Microsoft Test Manager)
 - Selenium (Automated UI coded)
 - Team Foundation Server 2015 (Test cases and User stories)</p>

<p>Web Application with URL</p>

<p>We only want to configure automated UI testing for our website. Is there any way to run the set up the automated testing without build through TFS?</p>

<p>Thank you and any feedback is appreciated.</p>
",https://stackoverflow.com/questions/41489297/run-automation-ui-testing-through-selenium-and-coded-ui-without-build-from-tfs,"['selenium', 'tfs', 'automated-tests', 'coded-ui-tests', 'microsoft-test-manager']",2520,FALSE,-1,3
Select treeview item with item path using C# - Used in Coded UI Testing,"<p>I need to select items in treeview in Coded UI Test automation. I came up with my own solution. I see some performance issues as it is running slow. Any suggestions on improving the performance?</p>

<p>This one I wrote as extension method that way I can use it inline with Treeview control. </p>

<p>Also, node path is custom with assumption that "">"" is not used in any item text. I have given example of node text in Summary</p>

<pre><code>    /// &lt;summary&gt;
    /// Selects item in a tree view control. 
    /// Eg nodePath: 2017&gt;Jan&gt;21. This will expand 2017 then Jan and select 21st date in treeview
    /// &lt;/summary&gt;
    /// &lt;param name=""parentControl""&gt;Tree view control&lt;/param&gt;
    /// &lt;param name=""nodePath""&gt;Path where the item to be selected is located. Parent and child are separated with '&gt;'&lt;/param&gt;
    public static void SelectItemInTreeView(this WpfTree parentControl, string nodePath)
    {
        char splitter = '&gt;';
        string[] treePath = nodePath.Split(splitter);

        WpfTreeItem parentNode = null;
        UITestControlCollection childNodes = parentControl.Nodes;
        bool itemSelected = false;
        string root = treePath[0];

        string lastItemInTreePath = treePath[treePath.Length - 1];
        foreach (string pathElement in treePath)
        {
            bool found = false;

            foreach (WpfTreeItem item in childNodes)
            {
                UITestControl itemCheck = item.GetChildren().Where(x =&gt; x.ControlType == ControlType.Text &amp;&amp; x.Name == pathElement).FirstOrDefault();
                if (itemCheck != null)
                {
                    found = true;
                    WpfTreeItem currentItem = null;

                    if (itemCheck.Name.Equals(lastItemInTreePath))
                    {
                        item.Selected = true;
                        itemSelected = true;
                    }
                    else
                    {
                        currentItem = (parentNode == null) ? new WpfTreeItem(parentControl) : new WpfTreeItem(parentNode);
                        currentItem.TechnologyName = ""UIA"";
                        currentItem.SearchProperties[WpfTreeItem.PropertyNames.Name] = item.Name;
                        currentItem.SearchConfigurations.Add(SearchConfiguration.ExpandWhileSearching);
                        currentItem.Expanded = true;

                        parentNode = currentItem;
                    }
                    break;
                }
            }

            if (!found)
            {
                Assert.Fail(""Error in Tree view path. Correct your input Treeview path: {0}"", nodePath);
            }
            else
            {
                if (!itemSelected)
                {
                    childNodes = parentNode.Nodes;
                }
            }
        }
    }
</code></pre>
",https://stackoverflow.com/questions/45321572/select-treeview-item-with-item-path-using-c-used-in-coded-ui-testing,"['c#', '.net', 'treeview', 'extension-methods', 'coded-ui-tests']",491,FALSE,0,0
How to check and uncheck a checkbox using automated UI testing in Xamarin.Forms,"<p>I want to write a automated UI testing for Xamarin.Form project where I have to Check multiple values in a CheckBox. I have tried using app.Repl() and tree method still I am not getting any solution. Please anyone can Help me out. Thank you in advance.</p>
",https://stackoverflow.com/questions/43756585/how-to-check-and-uncheck-a-checkbox-using-automated-ui-testing-in-xamarin-forms,"['xamarin.forms', 'automated-tests', 'ui-testing']",441,FALSE,0,0
"UI Testing Assertion as Utility Method doesn&#39;t return failure (Xcode 8, Swift 3)","<p>Stealing help from this <a href=""http://masilotti.com/xctest-helpers/"" rel=""nofollow noreferrer"">website</a>, I've implemented this fix to run a small wait function so I can make sure I wait for elements/pages/etc. to load before continuing testing. The fix works should I use the code directly in the test, but when I put it in a Utility Method in another class it won't return correct pass/fail results.</p>

<p>The problem is when running the following code:</p>

<pre><code>func testCreateGame() {
    let app = LauncherUtilityMethods.startApp()
    AllStageUtilityMethods().waitForElement(app.buttons[""THISDOESNOTEXIST""])
</code></pre>

<p>This element doesn't exist, but I'll still see a test pass.
Here is the utility method:</p>

<pre><code>    func waitForElement(_ element: XCUIElement, file: String = #file, line: UInt = #line) {
    let exists = NSPredicate(format: ""exists == true"")
    expectation(for: exists, evaluatedWith: element, handler: nil)

    waitForExpectations(timeout: 5) { (error) -&gt; Void in
        if (error != nil) {
            let message = ""Failed to find \(element) after 5 seconds.""
            self.recordFailure(withDescription: message, inFile: file, atLine: line, expected: true)
            XCTFail()
        }
    }
</code></pre>

<p>After I insert the direct XCTFail( ) in the if statement, the Test will then fail/pass accordingly. Is there a better way to handle this scenario? It seems redundant to effectively be failing my tests twice, but only one comes through to actually show as a failure.</p>

<p>I suppose I could just add a description on the XCTFail, but that is a less elegant approach as the actual .recordFailure option.
Thanks for the help!</p>
",https://stackoverflow.com/questions/42909169/ui-testing-assertion-as-utility-method-doesnt-return-failure-xcode-8-swift-3,"['swift3', 'xcode8', 'xctest', 'xcode-ui-testing']",343,TRUE,0,1
How to drag and drop an element for xcode-ui-testing in Xcode 9,"<p>UI Test for an ios-app, developed in Xcode 8 and swift 3.2.</p>

<p>I'm facing a problem to deal with drag and drop after upgrading Xcode version 8 to 9</p>

<p>I would like to drag an element <code>[i.e. button]</code> and drop it to another element <code>[i.e. on homepage]</code>.</p>

<p>For Xcode 8, I implemented it using below method:</p>

<pre><code>let sourceElement = app.buttons[""Video_Button""]

let destElement = app.scrollViews.scrollViews.images.element(boundBy: 0)

sourceElement.press(forDuration: 0.5, thenDragTo: destElement)
</code></pre>

<p>But the above code is not working in Xcode 9 and Swift 3.2.</p>
",https://stackoverflow.com/questions/47813639/how-to-drag-and-drop-an-element-for-xcode-ui-testing-in-xcode-9,"['xcode', 'xcode9', 'ios-ui-automation', 'swift3.2']",1151,TRUE,2,1
Best way to intercept a network call and providing mock response while UI testing,"<p>I am testing a login page on an android project and would like to intercept when the call is being called (When a button is clicked) and provide with a mock response (200 or 401 for ex) to prevent actually calling the network every time and to make automated unit testing faster. I usually just provide correct username/pass and Thread.sleep for a few until the request is done and I know this is not the correct way.</p>

<p>I am using retrofit 2 for my network calls and Espresso for UI testing. </p>

<p>I know how to mock a retrofit call but I want to mock exactly when the call is being executed in the login activity and send that activity a mock response.</p>
",https://stackoverflow.com/questions/45096321/best-way-to-intercept-a-network-call-and-providing-mock-response-while-ui-testin,"['android', 'unit-testing', 'retrofit2', 'android-espresso']",383,FALSE,2,0
Android UI Testing(Espresso): How to get all elements within a ListView with Espresso?,"<p>Let's say I have a ListView like the one shown in the picture below:</p>

<p>I want to write a UI test using Android Espresso and get ALL the visible elements within that list. After that I want to randomly click some row in the ListView and determine every one of them that was clicked and get the text from them. Is that possible? As I see, the Espresso documentation regarding ListView testing is pretty poor.
<a href=""https://i.stack.imgur.com/nAXeK.jpg"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/nAXeK.jpg"" alt=""enter image description here""></a></p>
",https://stackoverflow.com/questions/46471076/android-ui-testingespresso-how-to-get-all-elements-within-a-listview-with-esp,"['android', 'listview', 'automated-tests', 'ui-automation', 'android-espresso']",264,FALSE,2,0
Qt Auto-UI Testing stopping because of messagebox. How to simulate enter on messagebox?,"<p>My task is to write an automated UI test for a software being developed. It happens so, that there are radiobuttons triggering a messagebox, which stops my automated test until I manually confirm it (pressing ENTER). The issue is that I do not know how I can call that newly summoned messagebox and then have it confirmed by <code>QTest::keyClick(&lt;object&gt;, QtKey::Key_Enter);</code> and have my automated test continue the run.</p>

<p>I am using QWidgets, QApplication, Q_OBJECT and QtTest.
I will provide a code similar to what I am working with:</p>

<pre><code>void testui1(){
Form1* myform = new Form1();
myform-&gt;show();
QTest::mouseClick(myform-&gt;radioButton01, Qt::LeftButton, Qt::NoModifier, QPoint(), 100);
// Message box pops up and stops the operation until confirmed
QTest::mouseClick(myform-&gt;radioButton02, Qt::LeftButton, Qt::NoModifier, QPoint(), 100);
// again
...
}
</code></pre>

<p>How exactly can I script to confirm the message box automatically? The message box is only an [OK] type, so I don't need it to return whether I have pressed Yes or No. A <code>QTest::keyClick(&lt;target object&gt;, Qt::Key_Enter)</code> method needs to know to which object it should press enter to. I tried including <code>myform</code> into the object and it did not work. Googling I did not find the answer. I found the following result as not functioning for what I am looking for</p>

<pre><code>QWidgetList allToplevelWidgets = QApplication::topLevelWidgets();
foreach (QWidget *w, allToplevelWidgets) {
    if (w-&gt;inherits(""QMessageBox"")) {
        QMessageBox *mb = qobject_cast&lt;QMessageBox *&gt;(w);
        QTest::keyClick(mb, Qt::Key_Enter);
    }
}
</code></pre>
",https://stackoverflow.com/questions/44760110/qt-auto-ui-testing-stopping-because-of-messagebox-how-to-simulate-enter-on-mess,"['c++', 'qt', 'user-interface', 'testing', 'automated-tests']",1017,TRUE,2,1
How to access Two switches (elements) individually inside a tableview cell in UI Testing,"<p>I am in UI Testing one of my screen of my project. I have a tableview one of its cell is containing one and two switches.I am able to access the first cell's switch (element) easily by</p>

<pre><code>         let tablesQuery = app.tables
         let switchPrivateStream     =   tablesQuery.switches[""Make Private Stream""]
         switchPrivateStream.tap()
</code></pre>

<p><a href=""https://i.stack.imgur.com/jQGnN.png"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/jQGnN.png"" alt=""just like this""></a></p>

<p>but i am not able to find out any way to access the next remaining those two  switches (elements) which are in side cell.</p>

<p>Please tell me what i am doing wrong here?</p>

<p>the debug description of this screen is as Follows ( might be helpful )</p>

<p><strong><code>""Attributes: Application, 0x1c0380410, pid: 11294, {{0.0, 0.0}, {320.0, 568.0}}, label: \'DummyProject\'\nElement subtree:\n →Application, 0x1c0380410, pid: 11294, {{0.0, 0.0}, {320.0, 568.0}}, label: \'DummyProject\'\n    Window, 0x1c03800d0, Main Window, {{0.0, 0.0}, {320.0, 568.0}}\n      Other, 0x1c0380270, {{0.0, 0.0}, {320.0, 2.5}}\n      Other, 0x1c03804e0, traits: 8589934592, {{0.0, 0.0}, {320.0, 568.0}}\n        NavigationBar, 0x1c0380680, traits: 35192962023424, {{0.0, 20.0}, {320.0, 44.0}}, identifier: \'Create a Stream\'\n          Button, 0x1c03805b0, traits: 8589934593, {{8.0, 20.0}, {27.0, 44.0}}, label: \'back icon\'\n          Other, 0x1c0380820, traits: 8590000128, {{86.5, 30.0}, {147.5, 24.0}}, label: \'Create a Stream\'\n        Other, 0x1c0380750, traits: 8589934592, {{0.0, 0.0}, {320.0, 568.0}}\n          Other, 0x1c03808f0, traits: 8589934592, {{0.0, 0.0}, {320.0, 568.0}}\n            Table, 0x1c0380a90, traits: 35192962023424, {{0.0, 64.0}, {320.0, 504.0}}\n              Cell, 0x1c0380b60, traits: 8589934592, {{0.0, 64.0}, {320.0, 153.0}}\n                Button, 0x1c0380c30, traits: 8589934593, {{276.0, 75.0}, {33.0, 33.0}}, label: \'camera icon cover images\'\n                TextField, 0x1c0380d00, traits: 146029150208, {{10.0, 164.0}, {300.0, 50.0}}, placeholderValue: \'Stream Name\'\n                Image, 0x1c0380dd0, traits: 8589934596, {{0.0, 64.0}, {320.0, 153.0}}, identifier: \'add-stream-cover-image-placeholder\'\n                Other, 0x1c0380ea0, traits: 8589934592, {{15.0, 216.5}, {305.0, 0.5}}\n              Cell, 0x1c419e850, traits: 8589934592, {{0.0, 217.0}, {320.0, 170.0}}\n                TextView, 0x1c43804e0, traits: 140746078552064, {{10.0, 261.0}, {300.0, 98.0}}\n                StaticText, 0x1c4380680, traits: 8589934656, {{10.0, 242.0}, {300.0, 17.0}}, label: \'Stream Caption\'\n                Other, 0x1c43805b0, traits: 8589934592, {{15.0, 386.5}, {305.0, 0.5}}\n              Cell, 0x1c4380750, traits: 8589934592, {{0.0, 387.0}, {320.0, 60.0}}\n                Switch, 0x1c4380820, traits: 9007207844675585, {{263.0, 401.5}, {49.0, 31.0}}, label: \'Make Private Stream\', value: 0\n                StaticText, 0x1c43808f0, traits: 8589934656, {{10.0, 408.5}, {138.0, 17.0}}, label: \'Make Private Stream\'\n                Other, 0x1c43809c0, traits: 8589934592, {{15.0, 446.5}, {305.0, 0.5}}\n              Cell, 0x1c4380a90, traits: 8589934592, {{0.0, 447.0}, {320.0, 80.0}}\n                Switch, 0x1c4380b60, traits: 9007207844675585, {{263.0, 449.0}, {49.0, 31.0}}, label: \'Add Collaborators, Any one can edit\', value: 0\n                Switch, 0x1c4380c30, traits: 9007207844675585, {{263.0, 494.0}, {49.0, 31.0}}, label: \'Add Collaborators, Any one can edit\', value: 0\n                StaticText, 0x1c4380d00, traits: 8589934656, {{10.0, 456.0}, {138.0, 17.0}}, label: \'Add Collaborators\'\n                StaticText, 0x1c4380dd0, traits: 8589934656, {{10.0, 501.0}, {138.0, 17.0}}, label: \'Any one can edit\'\n                Other, 0x1c4380ea0, traits: 8589934592, {{10.0, 487.0}, {300.0, 0.0}}\n                  Other, 0x1c4380f70, traits: 8589934592, {{10.0, 487.0}, {300.0, 0.0}}\n                    CollectionView, 0x1c4381040, traits: 35192962023424, {{24.0, 487.0}, {273.0, 0.0}}\n                      Image, 0x1c0380f70, traits: 8589934596, {{291.5, 448.0}, {2.5, 36.0}}\n                      Image, 0x1c0381040, traits: 8589934596, {{26.5, 481.5}, {265.0, 2.5}}\n                Other, 0x1c0381110, traits: 8589934592, {{15.0, 526.5}, {305.0, 0.5}}\n              Cell, 0x1c03811e0, traits: 8589934592, {{0.0, 527.0}, {320.0, 80.0}}\n                Switch, 0x1c03812b0, traits: 9007207844675585, {{104.5, 561.5}, {49.0, 31.0}}, label: \'Collaborators can, Add Content, Add People\', value: 0\n                Switch, 0x1c0381380, traits: 9007207844675585, {{263.0, 561.5}, {49.0, 31.0}}, label: \'Collaborators can, Add Content, Add People\', value: 0\n                StaticText, 0x1c0381450, traits: 8589934656, {{10.0, 536.0}, {84.0, 17.0}}, label: \'Collaborators can\'\n                StaticText, 0x1c0381520, traits: 8589934656, {{10.0, 568.5}, {88.0, 17.0}}, label: \'Add Content\'\n                StaticText, 0x1c03815f0, traits: 8589934656, {{167.0, 568.5}, {88.0, 17.0}}, label: \'Add People\'\n                Other, 0x1c03816c0, traits: 8589934592, {{15.0, 606.5}, {305.0, 0.5}}\n              Cell, 0x1c0381790, traits: 8589934592, {{0.0, 607.0}, {320.0, 80.0}}\n                Other, 0x1c0381860, traits: 8589934592, {{0.0, 64.0}, {305.0, 0.5}}\n                Button, 0x1c0381930, traits: 8589934593, {{0.0, 64.0}, {137.0, 45.0}}, label: \'done button\'\n    Window, 0x1c0381a00, {{0.0, 0.0}, {320.0, 568.0}}\n      Other, 0x1c0381ad0, traits: 8589934592, {{0.0, 0.0}, {320.0, 568.0}}\n    Window, 0x1c0381ba0, {{0.0, 0.0}, {320.0, 568.0}}\n      StatusBar, 0x1c0381c70, {{0.0, 0.0}, {320.0, 20.0}}\n        Other, 0x1c0381d40, {{0.0, 0.0}, {320.0, 20.0}}\n        Other, 0x1c0381e10, {{0.0, 0.0}, {320.0, 20.0}}\n          Other, 0x1c0381ee0, traits: 8388608, {{6.0, 0.0}, {41.0, 20.0}}, label: \'No SIM\'\n          Other, 0x1c0381fb0, traits: 8388608, {{52.0, 0.0}, {15.0, 20.0}}, label: \'3 of 3 Wi-Fi bars\', value: SSID\n          Other, 0x1c0382080, traits: 8389120, {{138.0, 0.0}, {49.0, 20.0}}, label: \'7:49 PM\'\n          Other, 0x1c0382150, traits: 8388608, {{280.0, 0.0}, {35.0, 20.0}}, label: \'100% battery power, Charging\'\nPath to element:\n →Application, 0x1c0380410, pid: 11294, {{0.0, 0.0}, {320.0, 568.0}}, label: \'DummyProject\'\nQuery chain:\n →Find: Target Application 0x1c02a1c80\n  Output: {\n    Application, 0x1c0380410, pid: 11294, {{0.0, 0.0}, {320.0, 568.0}}, label: \'DummyProject\'\n  }\n""</code></strong></p>
",https://stackoverflow.com/questions/47754992/how-to-access-two-switches-elements-individually-inside-a-tableview-cell-in-ui,"['ios', 'iphone', 'xctest', 'xcode-ui-testing', 'xctestcase']",936,TRUE,-1,1
UI Testing Failure - Failed to receive event delivery confirmation within 30.2s of the original dispatch,"<p>I record one screen's UI Activity with xcode 7.3.1 ,when I test this recorded UI Activity on simulator Test function will pass.
But when same function with device I got this error.
I already removed animations from particular that screen.
I used xcode 7.3.1 &amp; iPhone 6 (10.3.2)</p>
",https://stackoverflow.com/questions/45672223/ui-testing-failure-failed-to-receive-event-delivery-confirmation-within-30-2s,"['ios', 'swift', 'xcode-ui-testing']",58,FALSE,1,0
iOS AppUITests - Code signing is required for product type &#39;UI Testing Bundle&#39; in SDK &#39;iOS 10.2&#39;,"<p>I am developing an iOS app. When i am running Tests/UITests with <code>Command + U</code> from Xcode, Build is failed with the below error. All of my targets provisioning profiles and certificates are okey, except i put Don't Code Sign for AppUITests target. Is there any way to run full unit &amp; ui tests without profiles, for example on simulator?</p>

<p>Error:
<a href=""https://i.stack.imgur.com/ZUZyP.png"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/ZUZyP.png"" alt=""Error""></a></p>
",https://stackoverflow.com/questions/42432161/ios-appuitests-code-signing-is-required-for-product-type-ui-testing-bundle-i,"['ios', 'xcode', 'unit-testing', 'provisioning-profile', 'xcode-ui-testing']",3050,TRUE,4,1
IOS UI Testing: How do I determine if the app under test switched to Settings App?,"<p>My App uses Location Services and I have code that alerts the user if Location Services are disabled.  This has a button that allows them to switch to the Settings app and enable it.  This works fine but I want to write a UI Test that detects it, if possible.</p>

<p>Currently, my UI Tests work correctly checking for the alert appearing and that it has a Settings button.  I can confirm the app switches to settings through either the simulator or physical device when the button is tapped.</p>

<p>I'm not sure I can tell that the Settings app itself appears through the UITest (that would be nice!) but I could check that the app under test entered the background (that would be good enough!)</p>

<p>In my AppDelegate I have print statements that confirm the app is going through applicationWillResignActive(...) and applicationDidEnterBackground(...)</p>

<p>I tried the following:</p>

<pre><code>let predicate = NSPredicate(format: ""self.state = XCUIApplication.State.runningBackground"", argumentArray: nil)

_ = self.expectation(for: predicate, evaluatedWith: app, handler: nil)
waitForExpectations(timeout: 10.0, handler: nil)

XCTAssertTrue(app.state == .runningBackground, ""Doesn't look like the Settings App was launched"")
</code></pre>

<p>and the console is flagging up that it is waiting on the expectation - it logs every second.  Note that 'app' is the instance of XCUIApplication() that I use in the test.  Eventually, the expectation times out and the test terminates because it wasn't fulfilled.  At that point, my two print statements (resigning active, entered background) appear on the console.  </p>

<p>It would seem that my app is working as expected but that the expectation isn't determining the change in app state.  I've tried setting the wait period to 60 secs but the result is the same so it isn't a case of not waiting long enough.</p>

<p>Without the expectation, i.e. the code goes straight from pressing the settings button to checking the assert, the assert fails because the app state is .runningForeground.  I thought that execution was happening too fast, hence the attempt to wait for the state change.  In this case, the assert fails, the test finishes and then ""Resigning active"" appears in the console, but not ""Entered background"".</p>

<p>This is ios11 on Xcode 9 and behaviour is the same in the simulator and physical device.</p>

<p>To sum up, the question is: what's the best way to programmatically test that the Settings app has launched?</p>
",https://stackoverflow.com/questions/46664371/ios-ui-testing-how-do-i-determine-if-the-app-under-test-switched-to-settings-ap,"['ios11', 'xcode-ui-testing', 'xcode9']",591,TRUE,0,1
System.Exception finger print didn&#39;t match while runnig test scripts in xamarin UI Testing for mobile app testing,"<p>I got a error i n mobile app testing.</p>

<p>System.Exception finger print didn't match  while runnig test scripts in xamarin UI Testing for mobile app testing</p>

<p>Anyone know the answer please advise.</p>

<p>Thanks!</p>
",https://stackoverflow.com/questions/43405475/system-exception-finger-print-didnt-match-while-runnig-test-scripts-in-xamarin,"['visual-studio', 'mobile', 'xamarin', 'automated-tests']",184,FALSE,1,0
"Property of children from lastSnapshot of an element in iOS UI Testing is always being empty, why?","<p>I'm studying the UI testing framework <em>WebDriverAgent</em> from facebook. It's very great and helpful. It almost contains all knowledge of iOS UI testing.</p>

<p>XCTest has many unpublic classes and properties. For example, XCUIElement has a property named lastSnapshot, and lastSnapshot also has many useful properties, like <em>label</em>, <em>identifier</em>, <em>frame</em>, <em>parent</em>, <em>children</em>, <em>pathDescription</em>, ect. Here's the question: </p>

<p>The <em>children</em> property is used to get all children elements from from certain element, just like the subviews from a view. But when I trying to get the value of <em>children</em> from lastSnapshot of an element, it is always being empty. While I can rightly get values of the other properties like label, identifier, parent, etc. This does troubled me for several days. Here's the exapmle code:</p>

<pre><code>- (void)testExample {
    XCUIApplication *app = [[XCUIApplication alloc] init];
    XCUIElement *windowElement = [app.windows elementBoundByIndex:2];
    XCUIElement *statusBarElement = [windowElement.query elementBoundByIndex:0];
    XCUIElement *otherElement = [statusBarElement.query elementBoundByIndex:1];
    XCUIElement *timeElement = [otherElement.query elementBoundByIndex:2];

    [timeElement query];
    [timeElement resolve];
    NSLog(@""lastSnapshot = %@"", timeElement.lastSnapshot);
    NSLog(@""children = %@"", timeElement.lastSnapshot.children);
}
</code></pre>
",https://stackoverflow.com/questions/46643491/property-of-children-from-lastsnapshot-of-an-element-in-ios-ui-testing-is-always,"['ios', 'children', 'xcode-ui-testing']",369,FALSE,0,1
XC UI Testing with AWS device farm giving error &quot;Setup Test skipped: Not enough suites found to execute&quot;?,"<p>Archive the project and created the IPA file with development profile after that followed the following link to create the UITest IPA </p>

<p><a href=""http://docs.aws.amazon.com/devicefarm/latest/developerguide/test-types-ios-xctest-ui.html"" rel=""nofollow noreferrer"">http://docs.aws.amazon.com/devicefarm/latest/developerguide/test-types-ios-xctest-ui.html</a></p>

<p>also to reconfirm whether I am doing any wrong checked the following tutorial </p>

<p><a href=""https://www.mobdesignapps.fr/blog/2016/9/17/running-your-test-on-aws-device-farm?utm_source=stackoverflow&amp;utm_medium=answer&amp;utm_term=37184633"" rel=""nofollow noreferrer"">https://www.mobdesignapps.fr/blog/2016/9/17/running-your-test-on-aws-device-farm?utm_source=stackoverflow&amp;utm_medium=answer&amp;utm_term=37184633</a></p>

<p>where the steps stated</p>

<p><strong>Prepare Your iOS XCTest UI Tests</strong></p>

<p>Before you upload iOS XCTest UI tests to Device Farm for testing, make sure that your iOS XCTest UI test runner bundle is contained within a properly formatted .ipa file. To create an .ipa file, you can place your my-project-nameUITest-Runner.app bundle in an empty Payload directory. Next, archive the Payload directory into a .zip file and then change the file extension to .ipa. The *UITest-Runner.app bundle is produced by Xcode when you build your project for testing, and it can be found in the Products directory for your project.</p>

<p>But whatever I do getting the following error and my test getting skipped
<strong>Setup Test skipped: Not enough suites found to execute</strong></p>

<p>Didn't understand what I have to do to make it working and can anyone please help to figure out the problem? Thanks in advance.</p>
",https://stackoverflow.com/questions/47958293/xc-ui-testing-with-aws-device-farm-giving-error-setup-test-skipped-not-enough,"['swift3', 'ios10', 'aws-device-farm', 'xcuitest', 'xcode9.2']",782,TRUE,3,4
Undefined symbols for architecture x86_64 testing my ViewController Swift,"<p>I'm actually trying to implement UI testing in my application with nimble-snapshot.
I'm facing a issue that I don't really understand.
I have been looking around but don't seems to find an answer to my problem.</p>

<p>My problem occurs when I try to instantiate my viewcontroller to try and test the view associated with it.The compilation always fails with this error message.</p>

<pre><code>Undefined symbols for architecture x86_64:
""__T06medici19LoginViewControllerCMa"", referenced from:
__T013mediciUITests13LoginViewTestC4specyyFyycfU_yycfU_ in 
testUILogin.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
</code></pre>

<p>My test code looks like this:</p>

<pre><code>import Nimble
import Nimble_Snapshots
import Quick
import UIKit

@testable import XXXXMyProject

class LoginViewTest: QuickSpec {

override func spec() {

    describe(""LoginView"") {
        var vcLogin: LoginViewController!

        beforeEach {
            let storyboard = UIStoryboard(name: ""Account"", bundle: nil)
            vcLogin = storyboard.instantiateViewController(withIdentifier: ""LoginViewController"") as! LoginViewController
            _ = vcLogin.view // To call viewDidLoad
        }

        it(""has a valid snapshot"") {

            expect(vcLogin.view) == recordSnapshot()
        }
    }
  }
}
</code></pre>

<p>Being quite new to UI testing I don't really understand what is causing this issue.
Any help or tips would be greatly appreciated on how to resolve this problem or improve my ui testing code.</p>

<p>Thank you in advance.</p>

<p>Martin</p>
",https://stackoverflow.com/questions/46664052/undefined-symbols-for-architecture-x86-64-testing-my-viewcontroller-swift,"['ios', 'swift', 'xcode', 'xcode9', 'swift4']",2094,TRUE,3,1
Signing for &quot;WebDriverAgentRunner&quot; requires a development team. Select a development team in the project editor,"<p>Is it mandatory to provide development team in the xconfig file?
I am trying to open Calculator from the iPad but is showing me Select a development team.</p>

<p>Appium version - 1.6.4
Xcode version - 8.3.2</p>

<p>Can anyone please help me?</p>

<p>Please find below the part of the error log.</p>

<blockquote>
  <p>Signing for ""WebDriverAgentRunner"" requires a development team. Select a development team in the project editor.
  Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'
  Signing for ""WebDriverAgentRunner"" requires a development team. Select a development team in the project editor.
  Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'
  Signing for ""WebDriverAgentRunner"" requires a development team. Select a development team in the project editor.
  Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'
  Code signing is required for product type 'UI Testing Bundle' in SDK 'iOS 10.2'</p>
</blockquote>

<p><strong>TEST BUILD FAILED</strong></p>
",https://stackoverflow.com/questions/44326387/signing-for-webdriveragentrunner-requires-a-development-team-select-a-develop,"['ios', 'xcode', 'appium']",5726,TRUE,2,1
Xcode UI Unit Tests and Permission Alerts,"<p>I'm working on a UI unit test for my app, and am trying to figure out how to automatically have the test framework click ""OK"" when the system presents an alert asking for permission to access contacts. </p>

<p>So far, I've looked at these four SO posts, and tried the various suggestions, but am still unable to get this to work:</p>

<p><a href=""https://stackoverflow.com/questions/40666197/xctest-app-tests-and-permissions-alerts/40677543#40677543"">XCTest app tests and permissions alerts</a></p>

<p><a href=""https://stackoverflow.com/questions/32148965/xcode-7-ui-testing-how-to-dismiss-a-series-of-system-alerts-in-code?noredirect=1&amp;lq=1"">Xcode 7 UI Testing: how to dismiss a series of system alerts in code</a></p>

<p><a href=""https://stackoverflow.com/questions/36753813/xcode-ui-testing-allow-system-alerts-series?noredirect=1&amp;lq=1"">Xcode UI Testing allow system alerts series</a></p>

<p><a href=""https://stackoverflow.com/questions/33875301/xcode-7-ui-testing-dismiss-push-and-location-alerts?rq=1"">Xcode 7 UI Testing: Dismiss Push and Location alerts</a></p>

<p>Here's what I currently am trying - however, the permissions dialog is still not being automatically accepted; the test waits for me to click ""OK"" before moving forward:
    func testApp() {</p>

<pre><code>    self.addUIInterruptionMonitor(withDescription: ""MyDescription"", handler: { (alert) -&gt; Bool in
        let button = alert.buttons[""OK""]
        if button.exists {
            button.tap()
            return true
        }
        return false
    })

    let app = XCUIApplication()
    app.launch()
    ...
    app.tap()
    ...
}
</code></pre>

<p>EDIT: 
Here's the change I've made based on @ad-johnson's suggestion:</p>

<pre><code>var app: XCUIApplication!

override func setUp() {
    super.setUp()

    continueAfterFailure = false
    app = XCUIApplication()

    addUIInterruptionMonitor(withDescription: ""Contact Auth"")
    { (alert) -&gt; Bool in if alert.buttons[""OK""].exists {
        alert.buttons[""OK""].tap()
        }
        return true }

    app.launch()
}


func testScreenshots() {
    app.tap()
    ...
}
</code></pre>
",https://stackoverflow.com/questions/47003459/xcode-ui-unit-tests-and-permission-alerts,"['ios', 'swift', 'xcode', 'xctest', 'xcode-ui-testing']",4286,TRUE,3,1
C# UI Automation to Test WinForm App that has Google Oauth Login,"<p>I have a WinForm C# Windows App and I am working on Automation UI Testing with it.</p>

<p>The current problem I have is...</p>

<p>When I do click ""Login with Google"", it opens Chrome for the OAuth, and return the token back to the app to do the login.</p>

<p>Is there anyway I can simulate those action? </p>

<p>I am new to Visual Studio Automation UI Testing but I have background to work with Selenium and its easy with Web App to enter credential for Google Login</p>

<p>Thanks</p>
",https://stackoverflow.com/questions/46477496/c-ui-automation-to-test-winform-app-that-has-google-oauth-login,"['c#', 'winforms', 'visual-studio', 'ui-automation', 'ui-testing']",308,FALSE,3,0
Unable to capture view hierarchy while running UI Tests,"<p>Is it possible to view the UI Hierarchy when running the app through a UI Testing target?</p>

<p>I'm getting a white screen that says ""Unable to capture view hierarchy. Check the console log for additional information""</p>
",https://stackoverflow.com/questions/43446911/unable-to-capture-view-hierarchy-while-running-ui-tests,"['swift', 'xcode', 'xctest', 'xcode-ui-testing']",5475,TRUE,2,2
XCTests failing to launch app in simulator intermittently,"<p>Has anyone experienced and fixed:</p>
<p>XCTests are failing intermittently to launch app in the simulator for UI testing (XCUI).
I am running through fastlane, different tests appear to fail each test run.</p>
<p>OSX: 10.12.3
iOS simulator: 10.0
Xcode 8.2.1
Fastlane 2.11.0</p>
<p>Attempted to fix it by adding a 3 second sleep between setup and launch in my tests, but it still appears, maybe not as often but still...</p>
<blockquote>
<p>UI Testing Failure - Failure attempting to launch
&lt;XCUIApplicationImpl: 0x600000231b20 no.something.bb.debug at
/Users/server/Library/Developer/Xcode/DerivedData/ex-gmtcdujyggxwfrarizpgaromjfxj/Build/Products/Debug-iphonesimulator/BB.app&gt;:
Error Domain=FBSOpenApplicationServiceErrorDomain Code=1 &quot;The request
to open &quot;no.something.bb.debug&quot; failed.&quot;
UserInfo={NSLocalizedDescription=The request to open
&quot;no.something.bb.debug&quot; failed., NSLocalizedFailureReason=The request
was denied by service delegate (SBMainWorkspace) for reason: Busy
(&quot;Application &quot;no.something.bb.debug&quot; is installing or uninstalling,
and cannot be launched&quot;)., BSErrorCodeDescription=RequestDenied,
NSUnderlyingError=0x6080002598f0 {Error
Domain=FBSOpenApplicationErrorDomain Code=6 &quot;Application
&quot;no.something.bb.debug&quot; is installing or uninstalling, and cannot be
launched.&quot; UserInfo={BSErrorCodeDescription=Busy,
NSLocalizedFailureReason=Application &quot;no.something.bb.debug&quot; is
installing or uninstalling, and cannot be launched.}}}</p>
</blockquote>
",https://stackoverflow.com/questions/41872848/xctests-failing-to-launch-app-in-simulator-intermittently,"['ios', 'xcode', 'xctest', 'fastlane']",4430,TRUE,19,2
How To Perform Data Driven Testing in Xcode,"<p>I am writing UI Tests in Xcode and want to do so using data driven testing.  How can this be accomplished using Xcode's new UI Testing Framework XCUI?  The test cases would be of the following form:</p>

<pre><code>class StepUnitFormatterTests: XCTestCase {
//&gt; (0, ""0 steps"")
//&gt; (1, ""1 step"")
//&gt; (2, ""2 steps"")
//&gt; (999, ""999 steps"")
//&gt; (1000, ""1,000 steps"")
//&gt; (1000000, ""1,000,000 steps"")
//&gt; (3.3, ""3 steps"")
//&gt; (-5, ""0 steps"")
func testFormat(_ numberOfSteps: Double, _ expected: String) {
    XCTAssertEqual(StepUnitFormatter().format(numberOfSteps), expected)
    }
}
</code></pre>
",https://stackoverflow.com/questions/44270540/how-to-perform-data-driven-testing-in-xcode,"['ios', 'swift', 'automated-tests', 'xcode-ui-testing', 'data-driven-tests']",1127,TRUE,1,2
Why espresso test is needed in Android?,"<p>Why automated UI testing using espresso framework important whereas manual testing is much more comfortable and time-saving. Because it doesn't need to write any test cases in code. Please kindly give some industry-level benefits of it.</p>
",https://stackoverflow.com/questions/41996865/why-espresso-test-is-needed-in-android,"['android', 'testing', 'android-espresso', 'recorder']",581,TRUE,0,1
How to click on &quot;Cancel search&quot; button programmatically?,"<p>I have a <code>&lt;input type=""search""&gt;</code>. For the purpose of UI testing, I want to click on the ""cancel search"" button:</p>

<p><a href=""https://i.stack.imgur.com/ahcwQ.png"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/ahcwQ.png"" alt=""White search field on the teal background, with text &quot;user&quot;, visible text cursor at the beginning of the input, search cancel button in a shape of the white cross on the gray circle, and awesome pixelated classic red arrow pointing at the cancel button with the text &quot;this&quot;""></a></p>

<p>The code for this snippet is just this:</p>

<pre><code>&lt;input type=""search"" value=""user""&gt;
</code></pre>

<p>Cancel button itself can be styled via <code>::-webkit-search-cancel-button</code> pseudo, but because it's pseudo, it's not part of the DOM and I don't know how to access it. Only Blink/Webkit-based browsers render this button for now, but because my markup is used in the CEF application, it's not an issue.</p>

<p>Unfortunately, just setting the value to empty string does not fire any events. As far as I know, clicking on that button triggers ""input"" and ""search"" events, but firing them myself seems to defeat the purpose of UI testing.</p>

<p>So, how I can do this with Selenium or just plain Javascript?</p>
",https://stackoverflow.com/questions/45776811/how-to-click-on-cancel-search-button-programmatically,"['javascript', 'html', 'selenium']",1028,TRUE,2,2
How to bypass Fitnesse SetUp/TearDown for an individual test?,"<p>We are using Selenium and Fitnesse for UI testing, where we open Firefox and perform all the UI related actions - click, fill fields, press button etc. </p>

<p>As part of our current test framework, FitnesseRoot has the SetUp/TearDown defined, to open/destroy the browser instance. All the Suites and Tests (around 300 in number) use the SetUp/TearDown as part of the UI testing.</p>

<p>I am trying to replace one of our simple tests with new fixtures for API testing, because API testing is way faster than the UI testing. The test itself is working fine, but the problem here is that even though my REST fixtures do not require a browser instance, SetUp opens it and TearDown tries to close it, but returns an exception (since the test under execution points to API driver class, while the methods in the TearDown belong to the UI Driver class).</p>

<p>I cannot remove the SetUp/TearDown, since it has an impact on 300 test cases, as mentioned above. Is there any way I can prevent one specific test from using the SetUp/TearDown? Or point the TearDown back to the UI Driver Class, so that the test does not throw an exception? </p>

<p><code>SetUp</code>:</p>

<pre><code>|import            |
|com.myapplication.fitnesse.ui|
|com.myapplication.util.restclient.fixtures|

!define slim.flags {-s 200}

!|script |                                                                                           
|start| my UI driver class|${SERVER}|${PORT}|FIREFOX|${PAGE_PATH}.${PAGE_NAME}|${PROXYSERVER}|
|debug mode          |false |     
</code></pre>

<p>Actual test:</p>

<pre><code>!define TEST_SYSTEM {slim}
| script | my API driver class | server ip:port | username | password|
| login |
| do something...|
</code></pre>

<p><code>TearDown</code>:</p>

<pre><code>|script              |
|logout              |
|destroyDriver       |
</code></pre>
",https://stackoverflow.com/questions/42231624/how-to-bypass-fitnesse-setup-teardown-for-an-individual-test,"['selenium', 'fitnesse', 'web-api-testing']",929,TRUE,2,2
Insert mock data into Core Data in UI Test,"<p>My application is currently using Core Data as the persistence and I want to do some UI testing with some mock data. Currently I am running the UI tests with the data stored previously whilst developing. Ideally I would like to insert some mock data into the MOC to allow me to write more UI tests. For my unit tests, I am inserting data from a JSON file into the managed object context in the setup function. I want to know if this is possible for UI tests?</p>

<p>I have tried looking this up online, but I have read so many different answers from people that I am just confused now. If this is not possible, could anyone recommend the best practice for UI testing with core data?</p>
",https://stackoverflow.com/questions/42284964/insert-mock-data-into-core-data-in-ui-test,"['swift', 'core-data', 'xcode-ui-testing']",1904,TRUE,5,1
Espresso Dagger 2.11,"<p>Struggling to use Dagger 2 for UI testing powered by Espresso. I'm trying to generate a dedicated test <code>@Component</code> under <code>androidTest</code> directory but getting this error:</p>

<pre><code>Error:Bad service configuration file, or exception thrown while constructing
Processor object: javax.annotation.processing.Processor: 
Provider dagger.android.processor.AndroidProcessor could not be instantiated:
java.lang.NoClassDefFoundError: com/google/common/collect/SetMultimap
</code></pre>

<p>Here's how dependencies look like:</p>

<pre><code>androidTestCompile ""com.google.dagger:dagger:2.11"",
androidTestCompile ""com.google.dagger:dagger-android:2.11""
androidTestCompile  ""com.google.dagger:dagger-android-support:2.11""
androidTestAnnotationProcessor ""com.google.dagger:dagger-compiler:2.11""
androidTestAnnotationProcessor ""com.google.dagger:dagger-android-processor:2.11""
</code></pre>

<p>Have anyone faced with this and has a clue how to solve it?</p>

<p>Thanks.</p>
",https://stackoverflow.com/questions/45459757/espresso-dagger-2-11,"['android', 'testing', 'android-espresso', 'dagger-2']",227,FALSE,1,1
Android Architecture Component ViewModel - How to mock ViewModel on test Activity?,"<p>I'm trying to setup UI testing similar to <strong>GithubBrowserSample</strong> and it looks like the sample project only has mock <code>ViewModel</code> for <code>Fragment</code> but not an example for <code>Activity</code>.</p>

<p>Here's my code where I am trying to test the <code>Activity</code> by mocking <code>ViewModel</code>. But the <code>ViewModel</code> is not getting set before <code>onCreate()</code> in Activity. </p>

<pre><code>@RunWith(AndroidJUnit4::class)
class MainActivityTest {

    val viewModel = mock(MainViewModel::class.java)

    @Rule
    @JvmField
    val activityRule = ActivityTestRule&lt;MainActivity&gt;(MainActivity::class.java, true, true)

    private val liveData = MutableLiveData&lt;Resource&lt;Object&gt;&gt;()

    @Before
    open fun setUp() {
        activityRule.activity.viewModelFactory = createViewModelFor(viewModel)
        `when`(viewModel.liveData).thenReturn(liveData)
        viewModel.liveData?.observeForever(mock(Observer::class.java) as Observer&lt;Resource&lt;Object&gt;&gt;)
        liveData.postValue(Resource.success(Object()))
    }

    fun &lt;T : ViewModel&gt; createViewModelFor(model: T): ViewModelProvider.Factory =
        object : ViewModelProvider.Factory {
            override fun &lt;T : ViewModel&gt; create(modelClass: Class&lt;T&gt;): T {
                if (modelClass.isAssignableFrom(model.javaClass)) {
                    return model as T
                }
                throw IllegalArgumentException(""unexpected model class "" + modelClass)
            }
        }
}
</code></pre>

<p>Can someone help me about this issue please?</p>
",https://stackoverflow.com/questions/47988514/android-architecture-component-viewmodel-how-to-mock-viewmodel-on-test-activit,"['android', 'kotlin', 'android-espresso', 'android-architecture-components', 'android-viewmodel']",4458,TRUE,11,1
How can I test the text that SVProgressHud displays?,"<p>I'm doing UI testing in Swift and the app I'm testing shows many update/progress messages using the pod SVProgressHud. I want to be able to verify whether the correct message is being displayed. How can I capture the SVProgress HUD and get its text?</p>
",https://stackoverflow.com/questions/47471939/how-can-i-test-the-text-that-svprogresshud-displays,"['swift', 'xcode-ui-testing', 'svprogresshud']",1296,TRUE,2,3
How to implement a core protractor framework for multiple projects,"<p>there is an idea to implement 'protractor core' which will be used by multiple projects for UI testing. At this moment I have an angular project 'project1' with e2e tests (cucumber-protractor-typescript) which are covering 'project1'. In future I expect 'project 2', 'project 3' ... which is also required UI testing. So I would like to have a separate project let's say 'protractor core' which could be used by any project for develop UI tests. The stucture should be smth like this:</p>

<ol>
<li><p>project 1 >>> (has dependency to 'protractor core')</p>

<ul>
<li>features</li>
<li>step_definitions > (access to api, smth common)</li>
</ul></li>
<li><p>project 2 >>> (has dependency to 'protractor core')</p>

<ul>
<li>features</li>
<li>step_definitions > (access to api, smth common)</li>
</ul></li>
<li><p>project 3 >>> (has dependency to 'protractor core')</p>

<ul>
<li>features</li>
<li>step_definitions > (access to api, smth common)</li>
</ul></li>
</ol>

<p>Really appreciate any <strong>examples</strong>, ideas, suggestions !</p>
",https://stackoverflow.com/questions/42578476/how-to-implement-a-core-protractor-framework-for-multiple-projects,"['angularjs', 'typescript', 'protractor', 'cucumber']",774,FALSE,1,2
Error: A session id is required for this command but wasn&#39;t found in the response payload,"<p>I want to do some UI Testing with a Headless Browser Engine.
Since we don't have a graphic unit in our Linux I have used docker for  <a href=""https://hub.docker.com/r/selenium/node-chrome/"" rel=""nofollow noreferrer"">chrome</a></p>

<p>And I setup a test:</p>

<pre><code>const chai = require('chai');
const expect = chai.expect;
const chaiAsPromised = require(""chai-as-promised"");
chai.use(chaiAsPromised);
const webdriverio = require('webdriverio');
const options = { desiredCapabilities: { browserName: 'chrome' } };

const browser = webdriverio
.remote({ host: 'localhost', port: 4444 })
.init({ browserName: 'chrome', version: '45' });

describe('webdriver.io tests', function() {
  it('is a third test', function() {
    browser.url('foo');
    expect(Promise.resolve(browser.getTitle()))
.to.eventually.equal('foo');
});
</code></pre>

<p>Test is run by:</p>

<pre><code>BABEL_ENV=dev npm run mocha-test --recursive=tests/mocha --compilers js:babel-register --require babel-polyfill
</code></pre>

<p>But all I get is:</p>

<pre><code>Error: A session id is required for this command but wasn't found in the response payload.
</code></pre>

<p>Can anyone help me?</p>
",https://stackoverflow.com/questions/45922525/error-a-session-id-is-required-for-this-command-but-wasnt-found-in-the-respons,"['node.js', 'selenium-webdriver', 'mocha.js', 'webdriver-io', 'google-chrome-headless']",1737,FALSE,1,0
How to mock metwork requests in calabash tests,"<p>I've written UI tests on calabash that interact with my backend. I need to mock network requests and give pre-configured json to my app instead of real response to server. How to implement in in Calabash? Should I switch my UI testing library to mockito or espresso?</p>
",https://stackoverflow.com/questions/43446640/how-to-mock-metwork-requests-in-calabash-tests,"['android', 'mocking', 'calabash']",105,FALSE,0,1
Saving Screenshot captured from XCUIScreenshot Function,"<p>I am trying to use the function screenshot in XCTest to capture a screen, but I am unable to understand how to save this screenshot on to a simulator device or physical device</p>

<p><a href=""https://developer.apple.com/documentation/xctest/xcuiscreenshot"" rel=""noreferrer"">https://developer.apple.com/documentation/xctest/xcuiscreenshot</a> </p>

<p>I am trying to Automate UI testing here and will need to capture a lot of screenshots for review. </p>
",https://stackoverflow.com/questions/47431573/saving-screenshot-captured-from-xcuiscreenshot-function,"['ios', 'swift', 'screenshot', 'xcode-ui-testing']",2698,TRUE,5,2
Android Espresso and multiple buildTypes in gradle file cause &quot;Class not found&quot; error,"<p>I use Espresso for UI testing and I have multiple buildTypes in gradle file. After recording espresso test, when I'm trying to run test it throws <code>Class not found:[package name]</code> error:</p>

<blockquote>
  <p>Process finished with exit code 1
  Class not found: ""com.example.myapp.SplashActivityTest""Empty test suite.</p>
</blockquote>

<p>This is my gradle file content buildType:</p>

<pre><code>   buildTypes {
    debug {
        debuggable true
        applicationIdSuffix "".debug""
        signingConfig signingConfigs.debug


    }
    development {
        initWith debug
        applicationIdSuffix "".dev""
        resValue ""string"", ""app_name"", ""DEV_My App""
        buildConfigField 'String', 'BASE_URL', '""http://192.168.100.124:8080/""'

    }
</code></pre>

<p>How can I solve this problem?</p>
",https://stackoverflow.com/questions/42643262/android-espresso-and-multiple-buildtypes-in-gradle-file-cause-class-not-found,"['android', 'android-gradle-plugin', 'android-espresso']",250,FALSE,1,0
Find an ActionLink in UITestControl which has no id specified with it while using Hand coded UI method,"<p>I want to use hand coded UI technique for UI testing of my ASP>NET MVC application.I have an a href  which resides inside a div container how do i find it using UITestControl?.</p>

<p>This is how the href is shown using </p>

<p><a href=""/Home/Stats""></a></p>

<p>I am unable to spy this control using code Test Builder</p>
",https://stackoverflow.com/questions/41735580/find-an-actionlink-in-uitestcontrol-which-has-no-id-specified-with-it-while-usin,['coded-ui-tests'],35,FALSE,0,0
Trigger Selenium Tests cases in the post build event,"<p>I have a requirement where i have to trigger the selenium test cases for UI testing in the post build event of the TFS build definition (i.e., after the the files have been deployed in the higher environment using udeploy) as part of CI (continuous integration) pipeline. Any ideas on how to achieve this?</p>
",https://stackoverflow.com/questions/47807090/trigger-selenium-tests-cases-in-the-post-build-event,"['selenium', 'continuous-integration', 'tfsbuild', 'post-build-event']",119,FALSE,-1,1
iOS KIF test failure,"<p>I am trying to learn automated UI testing with KIF in sample app. My simple test is failing continuously. 
My code : </p>

<pre><code>#import &lt;XCTest/XCTest.h&gt;
#import &lt;KIF/KIF.h&gt;

@interface AutomatedUITestsSampleUITests : KIFTestCase

@end

@implementation AutomatedUITestsSampleUITests

- (void)setUp {
    [super setUp];

    // Put setup code here. This method is called before the invocation of each test method in the class.

    // In UI tests it is usually best to stop immediately when a failure occurs.
    self.continueAfterFailure = NO;
    // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method.
    [[[XCUIApplication alloc] init] launch];

    // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this.
}

- (void)tearDown {
    // Put teardown code here. This method is called after the invocation of each test method in the class.
    [super tearDown];
}

- (void)testExample {

    [tester waitForViewWithAccessibilityLabel:@""LOGIN - Button""];

    [tester tapViewWithAccessibilityLabel:@""LOGIN - Button"" traits:UIAccessibilityTraitButton];
}
</code></pre>

<p>I have set Accessibility Label <code>LOGIN - Button</code> to a UIButton in my storyboard also Accessibility is enabled.</p>

<p>I am getting this in console : </p>

<pre><code>Test Case '-[AutomatedUITestsSampleUITests testExample]' started.
    t =     0.00s     Start Test at 2017-06-16 13:45:07.071
    t =     0.00s     Set Up
    t =     0.04s         Launch com.UITests.AutomatedUITestsSample
    t =     4.63s             Waiting for accessibility to load
    t =     8.77s             Wait for app to idle
    t =    10.48s     Tear Down
Test Case '-[AutomatedUITestsSampleUITests testExample]' failed (10.868 seconds).
Test Suite 'AutomatedUITestsSampleUITests' failed at 2017-06-16 13:45:17.939.
     Executed 1 test, with 1 failure (1 unexpected) in 10.868 (12.735) seconds
Test Suite 'AutomatedUITestsSampleUITests.xctest' failed at 2017-06-16 13:45:17.940.
     Executed 1 test, with 1 failure (1 unexpected) in 10.868 (12.739) seconds
Test Suite 'All tests' failed at 2017-06-16 13:45:17.941.
     Executed 1 test, with 1 failure (1 unexpected) in 10.868 (12.743) seconds
</code></pre>

<p>It's a very simple test. Why is it failing? Thanks in advance.</p>
",https://stackoverflow.com/questions/44584355/ios-kif-test-failure,"['ios', 'xcode-ui-testing', 'kif']",450,TRUE,0,1
Difference between cypress and a BDD framework like cucumber,"<p>can someone explain me the difference between cypress.io as testing framework and a BDD framework like cucumber e.g.
As far as I understand cypress.io is a ui-testing framework for javascript.
tests are written in javascript.
you can use scenarios to describe a flow through the app as e2e-test.
Is that similar to a behavior test or has this framework only focus on the ui?</p>

<p>Someone comes around the corner and says: Cucumber or JBehave is the same as cypress. I fear that's not true. but what are the arguments that can be answered.
I don't develop web-apps and it's hard for me to compare both solutions.</p>

<p>I try to clarify my question:
Imagine there's an application with backend services and a frontend (web-app) that uses these services. The backend represents complex workflows and the whole app shall be tested by a BDD Framework (e.g. cucumber). The major benefit is a kind of up-to-date documentation by feature- and scenario-descriptions. It's the core of a framework like cucumber. A further benefit it's of course the (maybe e2e) test itself. To have value it needs ui-testing to test the whole workflow. e.g. you could use selenium together with cucumber to handle this. I think cypress is a kind of testing framework like selenium, right? Only much better in many ways. But someone could say: ""oh ... cypress is the same as cucumber, because you can also define scenarios, etc ... But I believe, when we think about BDD then cypress has to be used in combination with cucumber and not as a new stand-alone BDD-Tool. From my point of view cypress is a great ui-testing framework, but ... not more?! I anncounced my question here to find answers for clarification.</p>
",https://stackoverflow.com/questions/47281710/difference-between-cypress-and-a-bdd-framework-like-cucumber,"['cucumber', 'cypress']",14013,TRUE,10,3
Start iOS UI test session without Xcode or xcodebuild,"<p>Test setup: a Windows PC and an iOS device connected by USB. Inside the device there is a MyAppUITests application that holds all XCTest-based UI tests required to test some UI-related things on this device. The question is: how to run this app so that it will actually perform tests and collect debug console output?</p>

<p>I am aware that there is a <a href=""http://www.libimobiledevice.org/"" rel=""nofollow noreferrer"">libimobiledevice</a> lib that allows me to do this:</p>

<pre><code>idevicedebug -u [udid] -e [some_env_variables] run [bundle_id]
</code></pre>

<p>But as far as I understand, this tool doesn't start a special UI test runner (as it described in <a href=""https://developer.apple.com/videos/play/wwdc2016/409/"" rel=""nofollow noreferrer"">this WWDC video</a>) which in turn does all the automated UI testing and produces debug output.</p>

<p>I know that Xcode can do that via GUI or via <code>xcodebuild</code> utility like this:</p>

<pre><code>xcodebuild -project myapp.xcodeproj -scheme ""MyAppUITests"" \
           -destination 'platform=iOS,name=MyTestDevice' test
</code></pre>

<p>And Xcode knows the magic trick on how to run test manager daemon that will run my UI tests correctly.</p>

<p>Is there a way to run my UI testing app through UI test using <em>libimobiledevice</em> or any other 3rd party tool available on Windows platform?</p>
",https://stackoverflow.com/questions/45487653/start-ios-ui-test-session-without-xcode-or-xcodebuild,"['ios', 'xctest', 'ui-testing', 'libimobiledevice']",906,FALSE,1,1
Xamarin UI test - how to open navigation drawer,"<p>I am testing my android app using Xamarin UI Testing tool and I have written the following test: </p>

<pre><code>public void login()
    {
        app.Tap(x =&gt; x.Id(""Activity.LoginActivity.RelativeLayout_email""));
        app.Tap(x =&gt; x.Id(""EditText_email""));
        app.EnterText(x =&gt; x.Id(""EditText_email""), ""matt@matt.matt"");
        app.Tap(x =&gt; x.Id(""EditText_password""));
        app.EnterText(x =&gt; x.Id(""EditText_password""), ""matt123"");
        app.PressEnter();
        app.Tap(x =&gt; x.Id(""Button_login""));
        app.WaitForElement(x =&gt; x.Id(""ImageView_OfferItem_photo""), timeout: TimeSpan.FromSeconds(120));
        app.SwipeLeftToRight();
        app.Tap(x =&gt; x.Id(""ImageView_OfferItem_photo"").Index(1));
    }
</code></pre>

<p>and at the end I want to open side navigation drawer but I am unable to do it, because I am using native menu icon, that has no id. I tried android.R.id.home, but it did not work, too.  </p>
",https://stackoverflow.com/questions/43498954/xamarin-ui-test-how-to-open-navigation-drawer,['xamarin'],1041,TRUE,0,4
UItesting : Click on UIcollectionview then testing it get failed,"<p>I am new at ui-testing. During recording, when I <em>tap</em> on <em>ui-collection view</em> first object is shown on UI and corresponding to code written in test-example method is:</p>

<pre><code>XCUIElement *window = [[app childrenMatchingType:XCUIElementTypeWindow] elementBoundByIndex:0];
    XCUIElement *element2 = [[[[window childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther].element;
    [element2 tap]; 
</code></pre>

<p>And when automating the test-example method, it's <em>unable to fetch first object of ui-collection view</em>. please suggest a way to do that. 
Thanks in advance.</p>
",https://stackoverflow.com/questions/46691376/uitesting-click-on-uicollectionview-then-testing-it-get-failed,"['ios', 'objective-c', 'xcode', 'uicollectionview', 'xcode-ui-testing']",3744,TRUE,0,1
Using XCTest in non-Test Target,"<p>I'm writing a reusable framework around XCTest for UI testing of several of our projects. For this I created a Cocoa Touch Framework project that I want to share via pods.</p>

<p>Is it possible to include XCTest into such a project (without extra test targets)? I'm getting errors that the XCTest module cannot be found even though I've linked <code>XCTest.framework</code> in the build phases. </p>
",https://stackoverflow.com/questions/44534912/using-xctest-in-non-test-target,"['ios', 'objective-c', 'swift', 'xcode', 'xctest']",1144,TRUE,2,1
Pinch UITesting iOS - zoomOut not working,"<p>I want to automate (validate) the zoomIn - zoomOut for GoogleMapView in iOS with UI Testing.</p>

<p>With the following code, I'm able to zoomIn (and it's working correctly):</p>

<p><code>mapView.pinch(withScale: 1.8, velocity: 1)</code></p>

<p>But I can't zoomOut, I tried the following options:</p>

<p><code>mapView.pinch(withScale: 1.2, velocity: 1)</code> (I was thinking that this will zoomOut, because the previous scale was to <code>1.8</code>, but not)</p>

<p>Also try using values between (0,1) ~ but this is just moving the map (not zoomIn)</p>

<p><code>mapView.pinch(withScale: 0.7, velocity: -1)</code>
<code>mapView.pinch(withScale: 0.9, velocity: -0.9)</code></p>
",https://stackoverflow.com/questions/43876923/pinch-uitesting-ios-zoomout-not-working,"['ios', 'swift', 'xcode-ui-testing']",386,FALSE,5,0
How do you test junit tests,"<p>How do we test the junit test cases we wrote? I thought manually testing ie create test data and asserting expected and actual values are okay is fine. But recently I have encountered a situation where junit tests were passing but the particular SUT code was failing during UI testing (that means the junit tests failed to guard the bug). </p>
",https://stackoverflow.com/questions/43217859/how-do-you-test-junit-tests,"['java', 'junit']",206,TRUE,1,4
Is it possible to use monotouch uikit in xamarin ui tests,"<p>I am currently writing ui tests and I would like to be able to check things like if the TableViewCell has been selected or not. I see in the monotouch uikit there is a Selected method listed. I have tried to use it but got no results(see code below). Does anyone know how this can be used for UI testing?:</p>

<pre><code>app.Query(e =&gt; e.Class(""UITableViewCell.Selected""));
app.Query(e =&gt; e.Class(""UITableViewCell"").Selected);
</code></pre>
",https://stackoverflow.com/questions/47569086/is-it-possible-to-use-monotouch-uikit-in-xamarin-ui-tests,"['c#', 'xamarin', 'xamarin.ios', 'xamarin.uitest']",57,TRUE,1,1
click() not working with xpath selector,"<p>I am new to UI testing and using Nightwatch. I'm unsuccessfully trying to click an element selected with xpath. It seems like a simple case, the element is asserted as visible, but it's not being clicked. </p>

<p><strong>css:</strong></p>

<pre><code>&lt;a class=""blabla"" href=""/xx/000/aaa""&gt;
  &lt;div class=""action-button__inner""&gt;Open This&lt;/div&gt;
&lt;/a&gt;
</code></pre>

<p><strong>selector:</strong></p>

<pre><code>openThis: {
      selector: '//div[text()=""Open This""]',
      locateStrategy: 'xpath'
    }
</code></pre>

<p><strong>command:</strong></p>

<pre><code>.waitForElementVisible('@openThis', 2000)
.click('@openThis');
</code></pre>

<p><strong>output:</strong></p>

<pre><code>  ✔ Element &lt;//div[text()=""Open This""]&gt; was visible after 74 milliseconds.
</code></pre>

<p>BUT, it's not clicking on it, so the following assertions fail. All help would be appreciated! Thanks a lot guys!</p>
",https://stackoverflow.com/questions/44806319/click-not-working-with-xpath-selector,"['xpath', 'selenium-webdriver', 'automated-tests', 'ui-automation', 'nightwatch.js']",571,TRUE,1,2
What is the right way to template Locators in Selenide/Selenium?,"<p>I'm trying to use Page Objects pattern in my UI testing. Many examples suppose to save By (Locator) in class fields. Other recommends to save WebElement (or SelenideElement, if you're using Selenide). Though, both are great for hardcoded locators, I don't see how to use this for locators where the path contains variables.</p>

<p>For example, how to save in class field this locator?</p>

<pre><code>public SelenideElement getTotal(String type) {
   return $(By.xpath(""//h4[contains(text(), '""+ type +""')]"");
}
</code></pre>
",https://stackoverflow.com/questions/42376565/what-is-the-right-way-to-template-locators-in-selenide-selenium,"['java', 'unit-testing', 'selenium', 'uitest', 'selenide']",702,TRUE,0,2
Adobe AIR mobile applications unit testing integration tests test automations,"<p>We are developing mobile games based on Adobe AIR and stage3D technology.
Is there any possibility to do unit tests, integrations tests, UI testing in such applications?
Are there any continues integration tools? Jenkins plugins or anything else?</p>

<p>After some researches we've found several tools for AS3 Unit testing but most of them are supposed to be used with FLEX apps.</p>

<p>Thanks.</p>
",https://stackoverflow.com/questions/44483455/adobe-air-mobile-applications-unit-testing-integration-tests-test-automations,"['unit-testing', 'actionscript-3', 'continuous-integration', 'integration-testing', 'stage3d']",60,FALSE,0,1
JUnit 4 - how to mock views ?,"<p>I have the following function I want to test :</p>

<pre><code>public void attemptLogin() {
        // Store values at the time of the login attempt.
        String userid = mUserIdView.getText().toString();

        if (TextUtils.isEmpty(userid)) {
            if (mCurrentUser != null) {
                userid = mCurrentUser.getUserId();
            }
        }
}
</code></pre>

<p>I want to write a unit test and give the function above an input for the userId. As can be seen, the function is doing :</p>

<pre><code>mUserIdView.getText().toString();
</code></pre>

<p>And causes the code to fail because the UI is not loaded (We have UI testing for that)
How would you recommend to test it ?
Thanks !</p>
",https://stackoverflow.com/questions/47754607/junit-4-how-to-mock-views,"['java', 'android', 'unit-testing', 'junit']",3116,TRUE,0,2
How can I crash an iOS app when a function designed for symbolic breakpoints is triggered?,"<p>I want to make sure that certain functions designed to be caught by symbolic breakpoints, such as <code>UIViewAlertForUnsatisfiableConstraints</code>, are not triggered during UI testing. However, I don't want to have the phone hooked up to the debugger and catching breakpoints. Instead, I want to crash the app somehow when these functions are run. How can I do this? Would dyld interposing help?</p>
",https://stackoverflow.com/questions/45358345/how-can-i-crash-an-ios-app-when-a-function-designed-for-symbolic-breakpoints-is,"['ios', 'breakpoints', 'dyld']",46,FALSE,0,1
Access playbackState of MPMoviePlayerController within UI Test,"<p>Is there a way to assess if a MPMoviePlayerViewController is playing or paused using XCTest's UI Testing framework?</p>

<p>I can manage to access the video element with this beautiful piece of code that was spit out by the recorder</p>

<pre><code>[[[[[[[[app.otherElements[@""VideoPlayer_ViewController""] childrenMatchingType:XCUIElementTypeOther] elementBoundByIndex:0]
                                                         childrenMatchingType:XCUIElementTypeOther].element
                                                         childrenMatchingType:XCUIElementTypeOther].element
                                                         childrenMatchingType:XCUIElementTypeOther] matchingIdentifier:@""Video""]
</code></pre>

<p>But I don't see anything in the XCUIElement interface or in the XCUIElementAttributes protocol that could help me assert that the player is playing or paused. Any suggestion?</p>
",https://stackoverflow.com/questions/43337331/access-playbackstate-of-mpmovieplayercontroller-within-ui-test,"['xcode', 'mpmovieplayercontroller', 'xctest', 'xcode-ui-testing']",106,TRUE,0,1
uiautomator version is not detected,"<p>I have uiautomator version 2 is installed in  my PC.
but when the appium severs runs below command</p>

<pre><code>adb -s b133582d shell uiautomator runtest AppiumBootstrap.jar -c io.appium.android.bootstrap.Bootstrap -e pkg io.ionic.starter -e disableAndroidWatchers false
</code></pre>

<p>the it return a warning as below:</p>

<p>This version of UI Automator is deprecated. New tests should be written using
UI Automator 2.0 which is available as part of the Android Testing Support Library.
See <a href=""https://developer.android.com/training/testing/ui-testing/uiautomator-testing.html"" rel=""nofollow noreferrer"">https://developer.android.com/training/testing/ui-testing/uiautomator-testing.html</a>
for more details.</p>

<p>How can I fix this issue?</p>
",https://stackoverflow.com/questions/47135384/uiautomator-version-is-not-detected,"['android-uiautomator', 'appium-android']",1705,TRUE,2,1
How to check whether the keyboard is shown or not?,"<p>I'm using <code>EarlGrey</code>for automated UI testing on an iOS project. I want to check whether the keyboard is shown or not after swiping away on the screen.</p>

<p>I've seen the header file in <code>EarlGrey</code> framework named <a href=""https://github.com/google/EarlGrey/blob/master/EarlGrey/Core/GREYKeyboard.h"" rel=""nofollow noreferrer"">GREYKeyboard.h</a> with a function named <code>isKeyboardShown</code> with a bool return value. This would be very helpful for me, but I don't know how to use it since I have no access to this API.</p>

<p><code>EarlGrey</code> is installed with <code>Carthage</code>.</p>
",https://stackoverflow.com/questions/46322413/how-to-check-whether-the-keyboard-is-shown-or-not,"['ios', 'swift', 'xcode', 'earlgrey']",758,TRUE,1,2
KIF alternatives for osx,"<p>I use <strong>KIF</strong> to perform iOS automated UI tests. Unfortunately it seems it is not intended to work in <strong>OSX</strong>. Is there any alternative for it?</p>

<p><strong>Update:</strong></p>

<p>I know there is a built-in UITest framework named XCTest for Apple applications, But I need a stronger and easier to use framework indeed.</p>

<p><strong>KIF</strong> makes UI testing really easy and useful, with lots of great APIs that are less complex than XCTest </p>
",https://stackoverflow.com/questions/46401096/kif-alternatives-for-osx,"['macos', 'xcode-ui-testing', 'kif', 'kif-framework']",175,FALSE,0,1
JavaScript: Instantiating a class from a JSON array,"<p>I have a TestComplete (UI testing) project which uses JavaScript, and I'm trying to store class references in JSON. It seems that my code isn't working, so I might have a conceptual misunderstanding of how JavaScript handles class references in JSON. Here's code which demonstrates my line of thinking:</p>

<pre><code>class MyClass {
  constructor() {
    this.name = ""ClassName"";
  }
}

function print_name(str_name) {
  console.log(str_name);
}

let my_json = {
    ""keyOne"": [
        MyClass
    ]
};

let class_ref = my_json[""keyOne""][0];
print_name(class_ref.name);
</code></pre>

<p>Is there a reason why the print_name function would fail to print the ""name"" property of the MyClass object?</p>
",https://stackoverflow.com/questions/47933679/javascript-instantiating-a-class-from-a-json-array,"['javascript', 'json', 'testcomplete']",167,TRUE,-2,1
TFS2015 running SoapUI test as unit tests - Error: Could not create the Java Virtual Machine,"<p>I'm trying to run SoapUI tests as unit tests as described here:
<a href=""http://blog.simplecode.eu/post/Soap-UI-testing-with-MsTest"" rel=""nofollow noreferrer"">http://blog.simplecode.eu/post/Soap-UI-testing-with-MsTest</a></p>

<p>Everything works nice when I'm running test locally in visual studio.
But when I'm trying to run those tests during the build process on tfs2015 i get ""Error: Could not create the Java Virtual Machine"":</p>

<p><a href=""https://i.stack.imgur.com/s5uf9.png"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/s5uf9.png"" alt=""enter image description here""></a></p>

<p>My other unit tests during that build are performed correctly.
Anyone had similar issue?</p>
",https://stackoverflow.com/questions/41467234/tfs2015-running-soapui-test-as-unit-tests-error-could-not-create-the-java-vir,"['visual-studio', 'tfs', 'msbuild', 'soapui', 'tfs-2015']",258,TRUE,0,2
Capybara: Screenshots with chrome are randomly dark,"<p>in our ui testing with capybara we are using chrome and chrome headless, since PhantomJS is deprecated.</p>

<p>We compare Screenshots to see if the page is looking exactly how it should look like. That works pretty fine, but there is a randomness, how chrome takes the screenshot. Sometimes the screenshots are pretty dark, which makes the test fail at the end. Is this a bug or am I missing something here?</p>

<p>Thanks already!</p>
",https://stackoverflow.com/questions/47095593/capybara-screenshots-with-chrome-are-randomly-dark,"['google-chrome', 'selenium-webdriver', 'cucumber', 'capybara', 'ui-testing']",191,TRUE,2,1
Ignore View controllers from XCTest coverage,"<p>I am making my first go to the unit testing. I am using MVVM and i can test pretty much everything with unit test (not ui test). The problem is that in the coverage my controller classes are showing up and that affect my coverage. Off course i can always do UI testing to cover those classes but i do not want. Is it possible to ignore from coverage all the classes that <code>import UIKit</code> ?</p>
",https://stackoverflow.com/questions/44462386/ignore-view-controllers-from-xctest-coverage,"['swift', 'unit-testing', 'code-coverage', 'xctest']",744,FALSE,2,1
jasmine-jquery isn&#39;t finding an element in my fixture file,"<p>I'm trying to do UI testing with jasmine-jquery. I'm using karma as my test runner and jasmine as my testing framework. I think I've loaded the fixture successfully and jasmine-jquery is listed as a testing framework inside my karma configuration.</p>

<p>However I'm unable to find an element in the DOM using jasmine-jquery. Why?</p>

<p>Directory structure</p>

<pre><code>base
 spec
  javascripts
   fixtures
    myfixture.html
karma.conf.js
tests
 settingUpHTMLFixtures.test.js
</code></pre>

<p>myfixture.html</p>

<pre><code>&lt;div id=""my-fixture""&gt;foo bar&lt;/div&gt;
</code></pre>

<p>settingUpHTMLFixtures.test.js</p>

<pre><code>jasmine.getFixtures().fixturesPath = 'base/spec/javascripts/fixtures';
loadFixtures('myfixture.html');
describe('testing out jasmine-jquery', function(){
  it('can find an element in the dom using jasmine-jquery', function(){
    expect($j('#my-fixture')).toBeInDOM();
  })
})
</code></pre>

<p>karma.conf.js</p>

<pre><code>const webpackConfig = require('./webpack.config.js');

module.exports = function(config) {
  config.set({
    basePath: """",
    files: [""tests/**/*.test.js"", 'spec/javascripts/fixtures/*.html'],
    frameworks: ['jasmine-jquery', 'jasmine', 'jasmine-matchers'],
    preprocessors: {
      ""tests/**/*.test.js"": [""webpack""]
    },
    webpack: webpackConfig,
    plugins : [
      'karma-chrome-launcher',
      'karma-jasmine',
      'karma-jasmine-jquery',
      'karma-jasmine-matchers',
      'karma-webpack',
      'karma-jasmine-html-reporter'
      ],
    logLevel: config.LOG_INFO,
    reporters: ['kjhtml'],
    port: 9876,
    browsers: [""Chrome""],
    //...
  });
};
</code></pre>

<p>At the moment I'm just getting the message that the test failed, which is
<code>testing out jasmine-jquery can find an element in the dom using jasmine-jquery FAILED
        Expected jQuery({ context: HTMLNode, selector: '#my-fixture' }) to be in d o m.
            at UserContext.&lt;anonymous&gt; (tests/settingUpHTMLFixtures.test.js:78:31)""</code> </p>
",https://stackoverflow.com/questions/47561902/jasmine-jquery-isnt-finding-an-element-in-my-fixture-file,"['jasmine', 'karma-runner', 'karma-jasmine', 'jasmine-jquery']",581,TRUE,1,1
Mockito Instrumentation Test,"<p>I am trying to use <code>Mockito</code> to perform Instrumentation Testing in Android.</p>

<pre><code>@RunWith(MockitoJUnitRunner.class)
public class LoginActivityTest {

    @Mock
    private FirebaseDatabase firebaseDatabase;
    @Mock
    private FirebaseAuth firebaseAuth;
    @Mock
    private LoginView view;

    @InjectMocks
    private LoginActivityPresenter presenter;

    @Test
    public void validateInput() {
        Assert.assertEquals(2 + 2, 4);
    }
}
</code></pre>

<p>After running the <code>validateInput</code> test, I am seeing ""No tests were found"" and ""Empty test suite."" Would you be able to tell me what I am doing wrong? It works perfectly if I write the same code for a typical unit test class.</p>

<p><strong>Note:</strong> I am just experimenting with Mockito and UI testing. I acknowledge that I could test the presenter only.</p>
",https://stackoverflow.com/questions/43286589/mockito-instrumentation-test,"['android', 'firebase', 'mocking', 'mockito', 'instrumentation']",534,TRUE,1,1
How to write tests for deep links in Android?,"<p>I would like to write tests for <a href=""https://developer.android.com/training/app-indexing/deep-linking.html"" rel=""noreferrer"">Android app with deep link cases</a> using UI testing framework (Espresso) - launch app using only ACTION_VIEW intent and check all views on opened screen. </p>

<p>But looks like Espresso (even espresso-intents) doesn't have this functionality, and require to define Activity class.</p>

<p>I tried this way, but it doesn't work properly, because launched app twice - standard launch using AppLauncherActivity (required by Espresso) and launch via deep link.</p>

<pre><code>@RunWith(AndroidJUnit4.class)
public class DeeplinkAppLauncherTest {

    @Rule
    public ActivityTestRule&lt;AppLauncherActivity&gt; activityRule = new ActivityTestRule&lt;&gt;(AppLauncherActivity.class);

    @Test
    public void testDeeplinkAfterScollDownAndBackUp() {
        Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(""myapp://search/777""));
        activityRule.launchActivity(intent);

        onView(withId(R.id.search_panel)).check(matches(isDisplayed()));
    }

}
</code></pre>

<p>I would like to launch testing app using only deep link without standard launch.
Do you know, how to do it?</p>
",https://stackoverflow.com/questions/42951216/how-to-write-tests-for-deep-links-in-android,"['android', 'deep-linking', 'android-testing', 'android-espresso']",5346,TRUE,12,3
How to get a the value of &quot;background-color&quot; property of an element that I have in my NATIVE App,"<p>I'm developing a test code in c# (v3.0.02 of Appium) and I need to get the value of ""background-color"" property of an element that I have in my NATIVE App.</p>

<p>Here is a part of the code:</p>

<pre><code>ReadOnlyCollection obj = driver.FindElementsByName(""lblProtocolo"");

for(int i=0;i&lt;obj.Count;i++)
{
var str = obj[i].GetCssValue(""background-color"");
}
</code></pre>

<p>but is throwing an exception:</p>

<pre><code>Test method ASEXamarin.Shared.Tests.TelaInicial.TesteRows threw exception: 
System.NotImplementedException: Not yet implemented. Please help us: http://appium.io/get-involved.html
</code></pre>

<p>There is any form to get this property in NATIVE Apps?</p>

<p>There is a related post in: 
<a href=""https://stackoverflow.com/questions/35164413/appium-android-ui-testing-how-to-verify-the-style-attribute-of-an-element/43187007?noredirect=1#comment73447089_43187007"">Appium Android UI testing - how to verify the style attribute of an element?</a></p>
",https://stackoverflow.com/questions/43187388/how-to-get-a-the-value-of-background-color-property-of-an-element-that-i-have,"['c#', 'appium']",872,FALSE,0,0
Trouble getting cucumber rerun plugin to work through terminal,"<p>I am using cucumber for ui testing written in java. I am trying to implement the cucumber plugin for rerunning failed scenarios, and created a second class to be the runner for those scenarios:</p>

<p>first class</p>

<pre><code>@RunWith(Cucumber.class)
@CucumberOptions(
        monochrome = true,
        strict = true,
        tags = {""@lakeisha""},
        features = ""."",
        format = {""html:target/cucumber"", ""json:target/cucumber.json""},
        plugin = {
                ""pretty"", ""html:target/cucumber-reports"",
                ""json:target/cucumber.json"",
                ""rerun:src/test/resources/rerun.txt"" //Creates a text file with failed scenarios
        })
public class RunCukeTestsIT extends BaseCucumberRunner {
}
</code></pre>

<p>second class:</p>

<pre><code>@RunWith(Cucumber.class)
@CucumberOptions(
        monochrome = true,
        tags = {""@lakeisha""},
        features = ""@src/test/resources/rerun.txt"", //Cucumber picks the failed scenarios from this file
        format = {""html:target/cucumber"", ""json:target/cucumber.json""}
)
public class ReRunCukeTestsIT extends BaseCucumberRunner{

}
</code></pre>

<p>and i am running the tests using </p>

<pre><code>mvn clean verify -Dcucumber.options="" --tags @lakeisha""
</code></pre>

<p>the problem is that running it through terminal doesn't seem to generate anything in the rerun.txt, but running it through IJ does. I also tried putting the plugin into Dcucumber.options portion of command, to no avail . Help much appreciated!</p>
",https://stackoverflow.com/questions/47718204/trouble-getting-cucumber-rerun-plugin-to-work-through-terminal,"['java', 'maven', 'cucumber', 'cucumber-jvm']",754,FALSE,6,0
Testing Android Apps with hardware component,"<p>I am looking for tools to help with testing my android app. It contains a hardware component and so far our only method is manual; obviously this isn't optimal. </p>

<p>The app uses the phones camera &amp; a hardware attachment. Normally I would look into espresso for UI testing and Junit for unit tests but I don't want to start and get nowhere.</p>

<p>An answer here would suggest testing tools, and how they get around the hardware and camera constraints.</p>
",https://stackoverflow.com/questions/42653250/testing-android-apps-with-hardware-component,"['java', 'android', 'testing', 'junit', 'android-espresso']",54,FALSE,0,2
"How to write a Stored Procedure to Select, Delete and then Insert?","<p>I am loading a sample data for my UI testing and for that I am trying to check if the data exists. If it is then delete it and insert the new one instead. I got almost 9 inserts and I am not sure if I need to check for each row if it exists then delete each row then insert. </p>

<p>This is the sample data that I am trying to load using SP.</p>

<pre><code>INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP', getDate(), getDate(), 1); 

INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP1', getDate(), getDate(), 1); 

INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP2', getDate(), getDate(), 2);  

INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP3', getDate(), getDate(), 3); 

INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP4', getDate(), getDate(), 4); 

INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP5', getDate(), getDate(), 5); ; 

INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP6', getDate(), getDate(), 6);  

INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP7', getDate(), getDate(), 7);  

INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE) VALUES 
(212019, 'SOURCE', 'COMP8', getDate(), getDate(), 8); 
</code></pre>

<p>Stored Procedure</p>

<pre><code>CREATE PROCEDURE TRANSACTION
@TRANSACTION_ID int,
@MDATA_ATTRB varchar,
@MDATA_VALUE varchar,
@ISACTIVE bit

AS
BEGIN
IF EXISTS (SELECT * FROM TRANS_MDATA WHERE TRANSACTION_ID = @TRANSACTION_ID)

BEGIN
DELETE FROM TRANS_MDATA WHERE TRANSACTION_ID = @TRANSACTION_ID
END

ELSE
INSERT INTO TRANS_MDATA (TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, CREATED_TIME, LAST_MOD_TIME, ISACTIVE)
VALUES (@TRANSACTION_ID, MDATA_ATTRB, MDATA_VALUE, getdate(), getDate(), @ISACTIVE)
END 
END

EXEC [TRANSACTION]
@TRANSACTION_ID = 123456,
@MDATA_ATTRB = 'Source',
@MDATA_VALUE = 'Backend',
@ISACTIVE bit = 1
</code></pre>
",https://stackoverflow.com/questions/46164325/how-to-write-a-stored-procedure-to-select-delete-and-then-insert,"['sql', 'sql-server', 'database', 'stored-procedures']",2082,FALSE,0,1
UI Automator / Ui Automator2 : Scroll and find child UI Element in Recycler View,"<p>I want to acheive something like this.<br>
    Open Gmail app, look for a particular mail (scroll also) and click on it.<br>
  In the method below, I am able to search for a particular mail and click on it.<br></p>

<pre><code>public void openMailWithParticularTitle(){
        UiObject2 obj =  Utils.getDeviceInstance().findObject(By.res(""com.google.android.gm:id/recycler_list_view""));
        List&lt;UiObject2&gt; mails = obj.findObjects(By.clazz(""android.view.View""));
        for(int i =0; i&lt;mails.size();i++){
            if(mails.get(i).getContentDescription()!=null &amp;&amp; mails.get(i).getContentDescription().contains(""My Mail Link"")){
                mails.get(i).click();
                break;
            }
        }
    }
</code></pre>

<p>But it only looks for visible items, doesn't scroll to look for child elements.<br>
So I looked around and tried this, but this also doesn't seem to work due to some reasons.<br></p>

<pre><code> public void scrollMailWithParticularTitle2() throws UiObjectNotFoundException {
        openApp(Const.package_gmail_app,true);
        UiScrollable settingsItem = new UiScrollable(new UiSelector()
                .className(""android.support.v7.widget.RecyclerView""));
        UiObject about = settingsItem.getChildByText(new UiSelector()
                .className(""android.view.View""), ""My Mail Link"");
        about.click();
    }
</code></pre>

<p><br>    Any help/ suggestion would be appreciated.
(I've limited knowledge of UI testing)</p>
",https://stackoverflow.com/questions/47278946/ui-automator-ui-automator2-scroll-and-find-child-ui-element-in-recycler-view,"['android', 'android-uiautomator']",9494,TRUE,2,2
XCUITest How to access the tableView header,"<p>I'm new on <code>XCUItest</code> and I haven't found the method to access to the header of a <code>tableview</code>. I'm running my test on <code>Xcode 7.3</code> ...</p>

<p>My <code>UIView</code> is composed as follow</p>

<p>HEADER</p>

<ul>
<li>Label 1</li>
<li>Label 2</li>
<li>Image</li>
</ul>

<p>CELL 1
....
....</p>

<p>CELL 2 
...
...</p>

<p>etc</p>

<p>To tap on the image inside the tableView header:</p>

<pre><code>let header = app!.tables.otherElements.elementBoundByIndex(0).otherElements[""label_header""]
let image_header = header.otherElements[""image_header""]
product_image_header.tap()
</code></pre>

<p>Always fails with error :</p>

<blockquote>
  <p>UI Testing Failure - No matches found for Other Query input was {(
  Other 0x7fbd95c250e0: traits: 8590000128, {{0.0, 64.0}, {375.0, 120.0}}, label: 'image_header' )}</p>
</blockquote>

<p>Have you a trick to have the full hierarchy of my view ? </p>

<p>Thanks for your help !</p>
",https://stackoverflow.com/questions/42374742/xcuitest-how-to-access-the-tableview-header,"['ios', 'swift', 'uitableview', 'xctest']",1950,FALSE,4,1
Espresso Testing: programmatically select &#39;never&#39; on smart lock save password,"<p>Doing espresso UI testing on Android and trying to bypass the smart lock screen. Issue is that we are testing in Firebase, and cannot turn off smart lock on the device as a whole since they are in the cloud (I don't believe). The popup is also not a part of the app itself, so I can't get the id using Stetho or Layout inspector. I believe it's another app (or OS feature) drawing on top of our app.</p>

<p>How can I hit the ""no thanks"" or ""never"" button in espresso?</p>

<p><a href=""https://i.stack.imgur.com/MQLBk.jpg"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/MQLBk.jpg"" alt=""Smart Lock""></a></p>
",https://stackoverflow.com/questions/44504969/espresso-testing-programmatically-select-never-on-smart-lock-save-password,"['android', 'android-espresso', 'google-signin', 'google-smartlockpasswords']",1091,TRUE,4,1
How to tap child element with KIF?,"<p>I use KIF-framework for UI-testing of the application on my job. One of the screens outputs the information in cells with text-fields and buttons which have the same accessibility labels in each cell, more some of them have dinamically changeable values. So if I use</p>

<pre><code>[tester tapViewWithAccesibilityLabel:@""&lt;buttonName&gt;""];
</code></pre>

<p>the button in the first cell will be tapped. 
I know how to specify the the button in definite cell, like</p>

<pre><code>[[[XCUIApplication alloc] init].tables.cells[@""&lt;cellName&gt;""].buttons[@""&lt;buttonName&gt;""] tap];
</code></pre>

<p>So how can I specify the same way using KIF? Or maybe, it has special method for that? </p>
",https://stackoverflow.com/questions/46173554/how-to-tap-child-element-with-kif,"['ios', 'objective-c', 'automated-tests', 'xcode8', 'kif-framework']",153,FALSE,1,0
Run and handle external application from python,"<p>I want to develop Python script that will open some windows-based application, then enter some data/commands simulating user using keyboard: </p>

<ul>
<li>Run MS Calculator then: ""5"", ""+"", ""8"", ""/"", ""2"", ""Enter"" and that's it</li>
<li>Run MS Notepad then: ""Hello world!"", ""Ctrl+s"", ""My file"", ""Enter"", ""Alt+F4""</li>
</ul>

<p>Of course it could return exiting code like 1 when succeed and write some logs.</p>

<p>I believe there is some library (probably for UI testing purpouses) but I don't know any.</p>

<p>I know there is Selenium but I'm afraid it's only for web browser app.</p>
",https://stackoverflow.com/questions/47122520/run-and-handle-external-application-from-python,"['python', 'windows', 'selenium', 'testing', 'autohotkey']",4005,TRUE,2,2
Xamarin.iOS UITesting - UnauthorizedAccessException,"<p>I ve been experimenting with Xamarin UI Testing on iOS for a while now and everything works as expected, except from the screenshots part. When doing app.Screenshot(""First""); I get the following error message:</p>

<blockquote>
  <p>System.Exception : Error while performing Screenshot(""First"")
  ----> System.UnauthorizedAccessException : Access to the path  ""/screenshot-1.png"" is denied.</p>
</blockquote>

<p>I have searched everywhere on the web, but I could not find a way to overcome this issue. Any help would be greatly appreciated!</p>

<p>P.S: I have also run Xamarin Studio with administrator privileges but again with no luck</p>
",https://stackoverflow.com/questions/41720049/xamarin-ios-uitesting-unauthorizedaccessexception,"['xamarin', 'xamarin.ios', 'ui-testing', 'unauthorizedaccessexcepti']",614,TRUE,1,1
"How do I get polymorphic tests working with cucumber-jvm, cucumber-serenity and SerenityObjectFactory","<p>I found an interesting blog explaining in general how to realize polymorphic step definitions using cucumber bdd and picocontainer dependency injection. You can visit the blog <a href=""https://cucumber.io/blog/2015/07/08/polymorphic-step-definitions"" rel=""nofollow noreferrer"">here</a> </p>

<p>Where I get stuck is not knowing how to keep the automation logic behind a ""generic"" interface and then provide two different implementations, One that talks directly to the domain model for unit-integration testing, and another one that uses Selenium WebDriver for UI-testing. </p>

<p>Can someone give me advise/skeleton how to implement this. I can't thank you enough for helping the community.</p>
",https://stackoverflow.com/questions/44522612/how-do-i-get-polymorphic-tests-working-with-cucumber-jvm-cucumber-serenity-and,"['java', 'dependency-injection', 'cucumber', 'cucumber-jvm', 'cucumber-serenity']",388,TRUE,0,1
Testing phone call service or wifi with appium in python,"<p>In python I want to know if i can test phone call service with appium so as Wifi or bluetooth .
the point is i can with appium press phone call button and dial number but how actually i can test that phone call is established ?
same is for bluetooth - wifi - phone pairing </p>

<p>one dumb way is to press dial button and compare dial screen with a presaved screen but this is only UI testing, not connection service testing.
if it can't be done with appium,do you know how it can be done ?</p>
",https://stackoverflow.com/questions/43984921/testing-phone-call-service-or-wifi-with-appium-in-python,"['python', 'selenium', 'appium', 'android-uiautomator', 'selendroid']",667,FALSE,0,1
Reactjs based web pages are not working with phantomjs headless,"<p>I am working UI-Testing for  mailapp.I wrote all test cases  and they are working fine on chrome and firefox.
When I am trying to run in Phantomjs for headless testing ,phantomjs is able to locate all elements on html web pages such as  it is working fine with logging but is not able to locate any elements in reactJS based web pages.phantomjs version is 2.1.1
I have searched all stackoverflow posts but nothing worked.</p>

<p>Any help would be appreciated
Thanks in advance.</p>

<pre><code> search_field=driver.find_element_by_id('search_text')
 search_field.send_keys(field_name)
</code></pre>

<p>It is giving output as</p>

<pre><code>NoSuchElementException: Message: {""errorMessage"":""Unable to find element with id 'search_text'"",""request"":{""headers"":{""Accept"":""application/json"",""Accept-Encoding"":""identity"",""Connection"":""close"",""Content-Length"":""92"",""Content-Type"":""application/json;charset=UTF-8"",""Host"":""127.0.0.1:55059"",""User-Agent"":""Python http auth""},""httpVersion"":""1.1"",""method"":""POST"",""post"":""{\""using\"": \""id\"", \""sessionId\"": \""75163a30-4cfc-11e7-8ad5-2f1b822b374a\"", \""value\"": \""search_text\""}"",""url"":""/element"",""urlParsed"":{""anchor"":"""",""query"":"""",""file"":""element"",""directory"":""/"",""path"":""/element"",""relative"":""/element"",""port"":"""",""host"":"""",""password"":"""",""user"":"""",""userInfo"":"""",""authority"":"""",""protocol"":"""",""source"":""/element"",""queryKey"":{},""chunks"":[""element""]},""urlOriginal"":""/session/75163a30-4cfc-11e7-8ad5-2f1b822b374a/element""}}
</code></pre>
",https://stackoverflow.com/questions/44455670/reactjs-based-web-pages-are-not-working-with-phantomjs-headless,"['python', 'reactjs', 'phantomjs']",217,FALSE,0,0
Recording Espresso tests with React Native,"<p>I'm creating an React Native application and I want to test it with Espresso.</p>
<p>When I click &quot;Record Espresso Test&quot;, I get the following error:</p>
<blockquote>
<p>No suitable Android Application configuration found</p>
<p>Please create an Android Application configuration with a valid module and Default or Specified launch activity.</p>
</blockquote>
<p>Also, I created a test manually, but the &quot;Run&quot; button is not available for the test.</p>
<p>I found this answer: <a href=""https://stackoverflow.com/questions/37167107/how-to-use-espresso-ui-testing-for-react-native"">How to use Espresso UI Testing for React Native?</a>
and set the <code>accessibilityLabel</code> for my resources, but that does not seem to have any effect.</p>
<p>I'm using Android Studio 2.2.3 for this</p>
",https://stackoverflow.com/questions/42295021/recording-espresso-tests-with-react-native,"['android', 'android-studio', 'react-native', 'android-espresso', 'android-espresso-recorder']",1191,TRUE,3,1
iOS UI Tests Linker Error,"<p>I'm trying to run some UI tests for my iOS app. I was successfully able to record my UI tests, but when running them, I get a linker error:
<a href=""https://i.stack.imgur.com/2eSkp.png"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/2eSkp.png"" alt=""enter image description here""></a></p>

<p>I have a UI Testing Target added to my project, and my UI Test file has been added to that target. </p>

<p>I've already been able to write and run several Unit Tests without a problem. </p>

<p>Anyone know where I should look to solve this, or have a guess what the problem may be?</p>

<p>EDIT: The full log output shows that the UI test file can't import an SDK that my target app relies on. </p>
",https://stackoverflow.com/questions/43872203/ios-ui-tests-linker-error,"['ios', 'xcode', 'xcode-ui-testing', 'mach']",513,TRUE,2,1
Measurement of UI application page load time,"<p>I have recently started working on UI testing and was wondering if there is any tool to figure out the time it takes to load the UI page to load in browser including the server response time ( i mean total browser time from request send till page load ).
I know that firebug/developer tools can be used to find it manually but is there any other way of doing it. Using selenium, i could use firefox driver and find out the time it takes to get the page and report that time, but i am not sure if it is the correct time. </p>
",https://stackoverflow.com/questions/44643596/measurement-of-ui-application-page-load-time,"['javascript', 'selenium', 'user-interface', 'web']",352,TRUE,1,1
how to test Promoting Your In-App Purchases,"<p>I am new in ios Development iOS11 Apple introduced IAP purchases that can be initiated from the AppStore &amp; it can be displayed in search results, and may be featured on an appropriate tab on the App Store.</p>

<p>for me not showing where Can i see the promoting my In-App Purchases UI ?</p>

<p><strong>Testing Promoted In-App Purchases</strong></p>

<p>To test your promoted in-app purchases before your app is available in the App Store, Apple provides a system URL that triggers your app using the itms-services:// protocol.</p>

<p><strong>The resulting URL looks like this:</strong></p>

<p>itms-services://?action=purchaseIntent&amp;bundleId=com.example.app&amp;productIdentifier=product_name</p>
",https://stackoverflow.com/questions/45726897/how-to-test-promoting-your-in-app-purchases,"['in-app-purchase', 'xcode9-beta5']",2317,TRUE,0,1
Select option from dropdown,"<p>I'm working on some automation and I came across one dropdown where I'm having an issue to select an option.</p>

<p>Only way, I was able to get the element is trough <code>IHTMLDocument3</code>:</p>

<pre><code>$dropdown = $ie.Document.IHTMLDocument3_getElementsByName(""searchTypeChoice"")
</code></pre>

<p>This is limiting my options how to select an option, since I can't use</p>

<pre><code>.Options.Selected = $true
</code></pre>

<p>or anything else. I found these questions:</p>

<ul>
<li><a href=""https://stackoverflow.com/questions/15150397/powershell-select-drop-down-menu-from-web-page"">Powershell..select drop down menu from web page</a></li>
<li><a href=""https://stackoverflow.com/questions/5379922/select-option-on-dropdown-list-for-web-ui-testing-automation-in-windows-powershe"">Select option on dropdown list for web ui testing automation in windows powershell</a></li>
</ul>

<p>This is the element I'm talking about:</p>

<p><a href=""https://i.stack.imgur.com/zTrlr.png"" rel=""nofollow noreferrer""><img src=""https://i.stack.imgur.com/zTrlr.png"" alt=""Dropdown""></a></p>

<p>Do you have any suggestions? Or maybe another method how to get the dropdown in other way?</p>
",https://stackoverflow.com/questions/41482917/select-option-from-dropdown,"['html', 'powershell', 'internet-explorer', 'automation']",1087,FALSE,0,1
How do I programmatically simulate a tap event on a view in NativeScript?,"<p>I am writing some code to do some automated UI testing of my NativeScript app.  The code will be hosted within the app itself, so I need to be able to drive UI events from the javascript code.  Specifically, I need to be able to programmatically cause a tap event to occur on a view.</p>

<p>Some searches on Google haven't turned up any good way to do this.  I saw a couple of similar questions containing suggestions to just call the tap event handler function directly, but this won't work when the arguments object is needed, because the direct call won't contain the NativeScript generated arguments object.</p>

<p>Any thoughts?</p>
",https://stackoverflow.com/questions/42662511/how-do-i-programmatically-simulate-a-tap-event-on-a-view-in-nativescript,['nativescript'],2623,TRUE,1,1
Xcode Workspace with Multiple Projects and Coca Pods Setup,"<p>Ok, let's start with the basics since I cannot friggin get this to work (see <a href=""https://stackoverflow.com/questions/45074383/xcode-workspace-not-finding-imports-from-framework-project-pod/45074659#45074659"">Xcode Workspace - Not finding imports from framework project pod</a>)...</p>

<p>I want to create an Xcode workspace that has two projects:</p>

<ol>
<li>Cocoa Touch Framework Swift project</li>
<li>Swift Demo app project for the framework</li>
</ol>

<p>Nr. 2 should also contain a UI Testing target.</p>

<p>Then I want to use Cocoapods to provide the WHOLE workspace (both projects!) as a pod AND I want to 'link' the framework project into the demo app project so that it can be used there.</p>

<p>Can somebody guide me through this incl. how the pod file needs to look for this?</p>
",https://stackoverflow.com/questions/45161400/xcode-workspace-with-multiple-projects-and-coca-pods-setup,"['ios', 'swift', 'xcode', 'cocoa-touch', 'cocoapods']",1996,TRUE,1,1
Swift UITest - No match found for textField with accessibility identifier,"<p>Trying to create a UITest for entering an email address/password into text fields and then hitting a login button. Using Xcode.</p>

<p>I watch the UITest navigate to the proper page, but it does not detect the text fields. I made sure that both text fields have the ""Accessibility"" box checked, and I've given them identifiers.</p>

<p>I'm getting this error:</p>

<blockquote>
  <p>UI Testing Failure - No matches found for text field</p>
</blockquote>

<pre><code>func testExample() {
    let app = XCUIApplication()

    //Test login page
    app.buttons[""loginButton""].tap()

    //Here it navigates to the desired page 
    let emailField = app.textFields[""email""]
    emailField.tap()
    emailField.typeText(""xxx.xx.edu"")

    let passwordField = app.textFields[""password""]
    passwordField.tap()
    passwordField.typeText(""xxx"")

    app.buttons[""loginButton""].tap()

   // let loginAlert = app.alerts[""alertVC""]

   // XCTAssertEqual(loginAlert.title, ""Error"")        
}
</code></pre>

<p>The accessibility indicators are ""email"" and ""password"" respectively. Logging in works fine when I run the simulator myself. </p>

<p>EDIT: Apparently there are no text fields at all (count = 0) even though I see them and use them on the page...</p>

<p>Image of storyboard with text fields:</p>

<p><img src=""https://i.stack.imgur.com/bTc5S.png"" alt=""image""></p>
",https://stackoverflow.com/questions/43575480/swift-uitest-no-match-found-for-textfield-with-accessibility-identifier,"['swift', 'xcode', 'textfield', 'uitest']",3376,TRUE,3,2
How to make waitForWebPageToLoad to work in coded ui test?,"<p>First of all, i'm a beginner at coded ui testing and i have poor code skills but im trying to learn.</p>

<p>Right now i'm hand coding some test cases (c#) in visual studio (the record option is not enough for me) but i can't get the <code>waitForWebPageToLoad</code> to work.</p>

<p>So for example below, i click a link, enter some text and click a button. After that i would like the code to wait for the webpage to load before proceeding. What i have done now is a <code>Thread.Sleep</code> but that's not a good solution...</p>

<pre><code>ClickLink(Repo.Link(Browser));
EnterText(Repo.Field(Browser), ""12345789"");
ClickButton(Repo.LeftButton(Browser));
Thread.Sleep(5000);  //&lt;-------- This must be replaced... :)
</code></pre>

<p>How do i get the <code>waitForWebPageToLoad</code> function to work?
I have this methods but i can't understand how to make them work, anyone wanna help me understand?</p>

<pre><code>void ClickButton(HtmlInputButton obj) {
    waitForWebPageToLoad(obj, 10);
    TestContext.WriteLine(""Clicking button: "" + obj.Name);
    Mouse.Click(obj);
}
</code></pre>

<h2>And:</h2>

<pre><code>void waitForWebPageToLoad(UITestControl parent, int waitTime) {
    waitTime = int.Parse(waitTime.ToString() + ""000""); //waitTimeExtension.ToString());
    Playback.PlaybackSettings.SearchTimeout = waitTime;
    parent.WaitForControlExist(waitTime);
    parent.WaitForControlReady(waitTime);
}
</code></pre>
",https://stackoverflow.com/questions/41815336/how-to-make-waitforwebpagetoload-to-work-in-coded-ui-test,"['c#', 'coded-ui-tests']",312,FALSE,3,1
Tapping on maps coordinates in Appium android,"<p>I'm automating an UI testing with Appium for android and I need to test some user inputs through a map. The map is a normal google map view, integrated in my app, and I need to press for 1 second on at least 3 points in that map.
My problem, now, is that my code skip this part and goes to the next lines without errors.
Here's my code</p>

<pre><code>    WebElement punto1=driver.findElement(By.className(""android.widget.RelativeLayout""));
    TouchAction touchAction=new TouchAction((MobileDriver) driver);
    touchAction.longPress(punto1, 309, 910, 3).perform();


    driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);

    WebElement punto2=driver.findElement(By.className(""android.widget.RelativeLayout""));
    TouchAction touchAction2=new TouchAction((MobileDriver) driver);
    touchAction2.longPress(punto2, 320, 890, 3).perform();
    driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);

    WebElement punto3=driver.findElement(By.className(""android.widget.RelativeLayout""));
    TouchAction touchAction3=new TouchAction((MobileDriver) driver);
    touchAction3.longPress(punto3, 299, 880, 3).perform();
    driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
</code></pre>

<p>I'm using the longPress(element, x,y, int duration time) and then I'm getting it pressed.
I tried to set the touch input in my area, as you can see, but I get the same problem</p>

<p>How can I solve this?
Thank you guys</p>
",https://stackoverflow.com/questions/42207566/tapping-on-maps-coordinates-in-appium-android,"['android', 'maps', 'appium']",678,FALSE,0,1
Running Xamarin unit tests on the target device,"<p>We are creating some unit tests to test our Xamarin C# code, and would like to run those unit tests automatically (Jenkins) on an actual target device (Android or iOS) connected to the Jenkins server, not an emulator.  There are various unit test frameworks (Touch.Unit, XUnit, NUnit) to help generate a unit test application, but then I can't find a way to run those unit tests on the actual device without using Xamarin's Test Cloud (which we will use for our UI testing, but we'd rather do unit testing in-house).</p>

<p>Is there a command-line option to Xamarin Studio (Mac) to say ""run this application on the specified device, and store the unit test output in the specified file""?</p>
",https://stackoverflow.com/questions/42356593/running-xamarin-unit-tests-on-the-target-device,"['unit-testing', 'jenkins', 'xamarin', 'xamarin-studio']",581,FALSE,1,1
