Testing in iOS - Part 29: Conclusion | Ray Wenderlich

I’m looking for some help understanding the sequence of synthesize events after a keyboard key is pressed. The keyboard key is pressed as:

let start = NSDate()
app.keys["\(letter)"].tap()
let end = NSDate()

I’m timing these operations because I’m chasing a problem where the key some times get stuck on the app (when users use it). The events printed are:

t = 3610.18s         Wait for com.xxxx to idle
   t = 3610.24s         Find the "A" Key
   t = 3614.35s             Check for interrupting elements affecting "A" Key
   t = 3614.35s         Synthesize event
   t = 3614.55s         Wait for com.xxxx to idle
Time difference is 4.660948038101196 sec

The sequence shows a find key and then 4 seconds later ‘Check for interrupting elements’. (The keyboard was already up and previous key presses were ok prior to this). Does this sequence mean XCTest was delayed by 4 seconds or that the app took 4 seconds before the key press was acknowledged?

Thanks

@bdmoakley Can you please help with this when you get a chance? Thank you - much appreciated! :]