我是黄瓜自动化测试的新手。需要你的帮助。如何点击这个值为“全部添加”的链接?
<div class="actions ui-header ui-helper-clearfix">
<a href="#" class="add-all btnadd" style="display: block; ">Add all</a>
</div>
我尝试过的对我不起作用:
if(page.find("a")[:href] == "add all")
click_on("Add all")
end
错误获取:
Ambiguous match, found 340 elements matching css "a" (Capybara::Ambiguous)
./features/step_definitions/Raffles_Winner.rb:223:in /^Editing newly added
raffle$/'