【发布时间】:2015-07-16 06:59:13
【问题描述】:
在我看来,我使用这个:
<%= file_field_tag 'my_file' %>
# html will be:
<input type="file" name="my_file" id="my_file" />
在我的规范文件中,我尝试了:
it 'file test' do
attach_file 'my_file', 'my/file/path'
end
但它说:
Capybara::ElementNotFound:
Unable to find file field "my_file"
【问题讨论】:
标签: ruby file rspec tdd capybara