javascript - Unable to enter texts in passcode textfields for iOS UI testing -
here's code run ui test on xcode:
var target = uiatarget.localtarget(); var app = target.frontmostapp(); var window = app.mainwindow(); //display current screen target.logelementtree(); //set value email address window.textfields()[0].setvalue("test11@test.com"); //set value in passcode window.textfields()[1].setvalue("1234"); window.buttons()["sign in"].tap();
for line:
window.textfields()[0].setvalue("1234");
it shows:
unexpected error in -[uiatextfield_0x7fc8ac0e360 setvalue:],/sourcecache/uiautomation_sim/uiautomation-430.2.1/frameworks/uielement.m.line 1088, kaxerrorcannotcomplete
so works when scripts enter email address, not passcode. thinking app detects passcode entered robot, not human. that's why produces error? if so, how fix it?
Comments
Post a Comment