Capybara in View spec? #39

Closed
giangnguyennet opened this Issue Jun 10, 2012 · 2 comments

Projects

None yet

3 participants

@giangnguyennet

As far as I know Capybara is for integration specs which stored in ./spec/requests/ directory so a bit confused when seeing this in View spec section:

Prefer the capybara negative selectors over should_not with the positive.

# bad
page.should_not have_selector('input', type: 'submit')
page.should_not have_xpath('tr')

# good
page.should have_no_selector('input', type: 'submit')
page.should have_no_xpath('tr')

Or am I missing something?

@markevich
Contributor

Capybara doesn't only used for integration specs. You can use gem for view specs too.

@bbatsov
Owner
bbatsov commented May 21, 2014

This section was removed from the guide.

@bbatsov bbatsov closed this May 21, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment