触摸特定坐标(UI测试)(Touch specific coordinate (UI tests))
如何触摸UITests的特定坐标?
当我在特定的地方录制时,我有类似的东西:
XCUIApplication *app = [[XCUIApplication alloc] init]; [[[[[[[[[[app.otherElements containingType:XCUIElementTypeNavigationBar identifier:@"Navigation Bar title"] childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther] elementBoundByIndex:0] childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther] elementBoundByIndex:0].staticTexts[@"Action"] tap];How can I touch specific coordinate with UITests?
When I'm recording tap on specific place, I have something like:
XCUIApplication *app = [[XCUIApplication alloc] init]; [[[[[[[[[[app.otherElements containingType:XCUIElementTypeNavigationBar identifier:@"Navigation Bar title"] childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther] elementBoundByIndex:0] childrenMatchingType:XCUIElementTypeOther].element childrenMatchingType:XCUIElementTypeOther] elementBoundByIndex:0].staticTexts[@"Action"] tap];更多推荐
发布评论