xcode-ui-testing Questions

2

Solved

I am trying to create UI test for my controller. I fill textfields and tap button and now I want to wait for dialog to appear and when it apears I want to tap Ok button and check what controller is...
Thais asked 30/3, 2016 at 16:26

2

When running ui tests via cli/fastlane on macOS Big Sur 12.3.0, Xcode 12.5.0 xcodebuild -showBuildSettings -workspace ./MyWorkspace.xcworkspace -scheme MyScheme-UITests xcodebuild[88311:3500544] ...
Honolulu asked 30/4, 2021 at 10:29

4

private func acceptPermissionAlert() { _ = addUIInterruptionMonitor(withDescription: "") { alert -> Bool in if alert.buttons["Don’t Allow"].exists { //doesnt get here s...
Marnimarnia asked 11/10, 2016 at 9:9

21

Solved

In my test I have a text field with a pre-existing text. I want to delete the content and type a new string. let textField = app.textFields textField.tap() // delete "Old value" textField.typeText...
Freiburg asked 28/9, 2015 at 11:28

29

Solved

This is my case: let passwordSecureTextField = app.secureTextFields["password"] passwordSecureTextField.tap() passwordSecureTextField.typeText("wrong_password") //here is an error UI Testing F...
Interspace asked 24/8, 2015 at 14:29

7

Solved

I have a very simple XCTestCase implementation that tests a tap on a button and expects an Alert controller to show up. The problem is that the tap() method doesn't work. Placing a breakpoint in th...
Workaday asked 17/5, 2016 at 12:44

2

Solved

I can't get UI tests to toggle a Toggle in a SwiftUI Form. It seems that app.switches[*name*].tap() does nothing. Does anyone else have experienced this? Ideas? The code below is a demonstration of...
Carmacarmack asked 20/4, 2023 at 9:39

7

Solved

Basically the problem is the same as this one: XCTestCase: Wait for app to idle I am using perpetually repeating "background animations" in my views. The UI testing of Xcode/iOS wants to ...
Mitchell asked 22/12, 2016 at 6:30

11

I just started with UI testing in Xcode 7 and hit this problem: I need to enter text into a textfield and then click a button. Unfortunately this button is hidden behind the keyboard which appeare...
Derisible asked 3/12, 2015 at 10:0

7

Solved

Is it possible to run individual test cases, or individual test suites, from an iOS app test target, instead of all the test cases, from a command line interface? You can run tests from command li...
Squaw asked 3/2, 2016 at 0:9

3

Solved

I've been writing UITests, and after recording a test to open a modal view, and swipe the modal down to the bottom of the screen to dismiss it, I get some code like this (as there is a table view i...
Masters asked 24/12, 2019 at 3:33

8

I would like my app to run special code (e.g. resetting its state) when running in UI Testing mode. I looked at environment variables that are set when the app is running from UI Testing and there ...
Rom asked 31/8, 2015 at 21:45

4

I'd like to update the location of the simulator in the middle of my UI test so that I can check the behavior as the location changes. Is there a way for the UI Test to somehow "call out" to run an...
Ironsmith asked 9/8, 2016 at 17:11

5

Solved

Is there a way to move UISlider under UITests target in Xcode? I really need to move it from code. Is it possible?
Kendra asked 9/2, 2016 at 17:25

3

Solved

I have several UI tests that I can successfully individually or grouped. I ended up breaking my tests up into specific classes and running them that way. The issue I've come across is Xcode execute...
Areta asked 13/11, 2015 at 18:13

4

Solved

I'm interested how to find the location of a screenshot which is created during UI Tests of my app. I would like to understand how Fastlane Snapshot grabs this screenshot. After couple of hours of ...
Lambeth asked 17/5, 2016 at 18:23

3

My UI-test fails because the test waits endless until the app idles. I can not see that there is anything happening in the background, like a loading spinner. It just occurs on one tab. All others...
Dee asked 10/11, 2015 at 7:12

17

Solved

I am trying to add UI tests to my existing project using Xcode 7. However the UI test recording button is always greyed out. What I am missing here? I tried restarting Xcode, cleaning and rebuild...
Corroboration asked 7/8, 2015 at 9:54

4

Solved

I tried to get my app name in UITesting. I tried the code below: let appName = Bundle.main.object(forInfoDictionaryKey: "CFBundleDisplayName") as! String But it gives me the nil value result.
Audiogenic asked 27/3, 2018 at 12:26

3

Solved

So I have a situation in which I have a few textFields that are validated. I'm trying to run a UI test, and when they fail they will get an alert to pop up with an error message (potentially a diff...
Teeter asked 12/10, 2015 at 16:47

12

Solved

In my App I'm using NSLocalizedString to localize my app. Now I want to switch to UITests and have Testcode like this: [tabBarsQuery.buttons["particiants"] tap]; This works for English b...
Caniff asked 9/11, 2015 at 12:40

10

Solved

I am trying to dismiss the search field by tapping 'Cancel' button in search bar. The test case is failing to find the cancel button. It was working fine in Xcode 7.0.1 I have added predicate to ...
Schulte asked 29/10, 2015 at 19:10

3

Solved

In my app there is a label which is contained inside a simple view. The view has a tap recogniser which will trigger a function ("why not using a button?" you might ask..well, we had to perform som...
Glyptics asked 15/12, 2015 at 11:58

3

I have UITests for my app and all the tests are running fine, but sometimes after executing a couple of tests, the other tests start failing due to Failed to terminate com.test.abc:3708 after 60.0s...
Discomposure asked 25/4, 2018 at 7:4

4

Solved

Every time we change something in the UI, we have to manually prepare and take 375 (= 5 screenshots * 5 device types * 15 languages) screenshots for iTunes Connect's listing. I'm trying to "exploi...
Argyle asked 18/6, 2015 at 6:11

© 2022 - 2024 — McMap. All rights reserved.