2
不選擇的第一要素經過的部位來模擬自動完成應該選擇的第一要素。這裏是HTML代碼谷歌自動完成在量角器
<input type="text" class="textareanoborder col-xs-12 col-md-12 m-t ng-pristine ng-valid ng-isolate-scope ng-touched" placeholder="Enter Location" ng-autocomplete="result1" details="details1" options="options1" rows="1" ng-model="location" autocomplete="off" aria-invalid="false">
這裏之後是量角器代碼:
browser.actions().mouseMove(element(by.model("location")).sendKeys("hyderabad,Telangana,India",protractor.Key.ARROW_DOWN)).click();
以下錯誤投擲:
Failed: unknown error: Element is not clickable at point (736, 231). Other element would receive the click: <div class="pac-item">...</div>
(Session info: chrome=54.0.2840.99)
(Driver info: chromedriver=2.25.426923 (0390b88869384d6eb0d5d09729679f934aab9eed),platform=Windows NT 10.0.14393 x86_64)
Thanks.it worked @BarretV – Shiva