0

I have a view and five buttons in an array on a uistackview drawn on a storey board: However, when I record, it always hit the third button and I cannot randomise which button to hit Code is:

 let app = XCUIApplication()
        let oneElement = app.otherElements["First"]
        let twoElement = app.otherElements["Two"]

 if oneElement.exists
            {
                oneElement.tap()
            }

            if twoElement.exists
            {
            twoElement.tap()

            }

TwoElement is the one that taps the button How can I direct the tap to button 1 or 0?

user3238267
  • 75
  • 1
  • 6

3 Answers3

0

otherelements is what was provided by the recording. I will sned the debug description in a few hours

0
otherElements 

is what was provided by the recording. I will send the debug description in a few hours

0

this is what was provided by the recording. I will send the debug description in a few hours