我无法使用 selenium 测试表单中的 Tokeninput 字段。情况是当我们输入一些东西时,它会给出一个选项列表以供选择,但这些选项不是 DOM 的一部分。文本填充字段但不选择项目。
我写的代码是:
Given admin user is on schedule interview page
And he select "obie[1]" and "DHH[1]" from the candidate name(s) auto sugget field
**step defination**
Given /^he select "([^"]*)" and "([^"]*)" from the candidate name\(s\) auto sugget field$/ do |arg1, arg2|
within(:css, "#interview_template_candidate_names_input") do
fill_in('tmp',:with => arg1) --tmp is name of the token input field
find("li:contains('obie[1])'").click
save_and_open_page
end
end