0
Hy!我正试图在葫芦ios中编写预定义的步骤来查找带有特定标题的按钮。我的问题是如何在葫芦中使用标题标签找到某个UIButton?我已经试过如下:如何通过标题标签在葫芦ios中查找UIButton?
Then (/^I see button with title "([^\"]*)" disabled$/) do |buttonTitle|
buttons = query("UIButton").compact
buttons.each do |button|
if query(button, :titleLabel, :text) == buttonTitle
fail(msg="Button found")
return
end
end
end