John Wu wrote in post #961880: > Hi everybody: > > I'm writing tests for a future application with Cucumber and Capybara > and I just want > to know if there is anyway to check if the download links and/or the > files are OK.
Why do you want to use Cucumber to test that the files are OK? It seems to me that this is properly done in your model specs, by testing the methods that generate the files. An example scenario would be the following one: > > Scenario: Checking links > Given I am logged in as ... > When I follow ... > And I click on "Download" > Then I should download "File1.zip" > > > Is it possible to do or is there any other way to do something similar? > Thanks. This should be possible, perhaps by parsing response_body as suggested at http://nhw.pl/wp/2009/09/09/testing-binary-downloads-with-webrat . Best, -- Marnen Laibow-Koser http://www.marnen.org mar...@marnen.org -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.