是否有人成功地使用addUIInterruptionMonitor清除start()在运行XCUITest时对SFAuthenticationSession生成的警报?
我无法让它在Xcode 9.1/iOS 11.1.1 (模拟器或设备)上工作。标准建议 (设置处理程序并随后在警报出现之前与设备交互)没有帮助。
测试记录器说app.alerts.firstMatch.buttons["Continue"]).tap()应该能做到这一点,但这也不起作用。这技术来自另一个,所以答案有时有效,但在CI上不一致。
所以我想知道这个“官方”解决方案是否对任何人有效。
发布于 2018-10-16 22:10:05
我没办法让它起作用:
let continueButton = app.alerts.buttons["Continue"]
XCTAssert(waitAndTap(continueButton), "could not tap on alert \"Continue\" button"但这次黑客攻击似乎起到了关键作用:
let statusBarsQuery = app.statusBars
statusBarsQuery.element.tap()https://stackoverflow.com/questions/47351709
复制相似问题