【发布时间】:2015-06-18 13:02:12
【问题描述】:
我在尝试使用 ios 应用上的滑动功能时遇到问题。目前使用 Appium v1.3.5 和 Cucumber/RubyMine v7.04。
我尝试过使用一系列 x、y 坐标。但是我仍然只能滑动到一半,无法点击屏幕上的元素。
以前有人遇到过这个问题吗?
def self.hide_thread
action = Appium::TouchAction.new
action.press(x: 360, y: 70).move_to(x: 0, y: 70).release
sleep(1)
find_element(:xpath,"//UIAApplication[1]/UIAWindow[1]/UIATableView[1]/UIATableCell[1]/UIAButton[1]").click
end
请错误提示:
elementId 18 could not be tapped(Selenium::WebDriver::Error::UnknownError)
./features/step_definitions/hidden_threads.rb:82:in `hide_thread'
./features/step_definitions/hidden_threads.rb:102:in `/^Hide the thread$/'
features/hidden_threads.feature:8:in `And Hide the thread'
Then Thread will be hidden # features/step_definitions/hidden_threads.rb:105
【问题讨论】: