in xctest need simulate tapping on uiimageview. uibutton use sendactionsforcontrolevents
method:
sendactionsforcontrolevents(uicontrolevents.touchupinside)
but looks uiimageview not have method. there way simulate tapping on uiimageview in xctest?
you can override touchesended function
override func touchesended(touches: nsset, withevent event: uievent) { touch: anyobject in touches { let location = touch.locationinnode(self) let node: sknode = nodeatpoint(location) if node.name == "scale" { } } }
and tapped element location.
Comments
Post a Comment