Hello,

For some acceptance tests I want to include screenshots, which are made 
during my specs, to the report (thus not just for failing specs).
The watir-rspec readme states:

You can use Watir::RSpec.file_path to have links automatically in the html 
report to the files created during tests.

uploaded_file_path = 
Watir::RSpec.file_path("uploaded.txt")File.open(uploaded_file_path, "w") 
{|file| file.write "Generated File Input"}file_field(:name => 
"upload-file").set uploaded_file_path

Where do I put this code? When I put it in my spec_helper.rb, I get this 
error: undefined method `file_field' for main:Object (NoMethodError)
Anyone has some ideas what I'm doing wrong?

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

[email protected]
http://groups.google.com/group/watir-general
[email protected]

--- 
You received this message because you are subscribed to the Google Groups 
"Watir General" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to