-
Notifications
You must be signed in to change notification settings - Fork 319
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Responsive tests #95
Comments
Unless there's a way to setup the driver multiple times with different window sizes (mobile, tablet, desktop, default, etc) at the start and then switch to the relevant one similar to what has been done for the date input tests (https://github.com/eliotsykes/rspec-rails-examples/blob/master/spec/features/subscribe_to_newsletter_spec.rb#L5). |
@amnesia7 good article, thanks for sharing. If a feature spec with responsive tests like this was added - I'm trying to think of what could be tested - possibly some nav that changes signficantly based on window width. It looks like the poltergeist driver has a resize method: http://www.rubydoc.info/gems/poltergeist/Capybara/Poltergeist/Driver#resize-instance_method |
Yeah, within a scenario you can do Navbar would probably be something that a lot of users can relate to that tests for |
I saw this http://railsware.com/blog/2015/02/11/responsive-layout-tests-with-capybara-and-rspec/ and thought it might be a good addition to the rspec examples.
I'm not entirely sure how it would be best applied because I couldn't actually get it to work when using the
poltergeist
driver so I assume it relies on theselenium
driver which is a shame if it can't be tested headless because that does add a lot of time onto the test run.The text was updated successfully, but these errors were encountered: