support for and/or compounding of rspec matchers with tests #1328

Merged
merged 1 commit into from Jun 12, 2014

Conversation

Projects
None yet
3 participants
Collaborator

twalpole commented Jun 11, 2014

No description provided.

Collaborator

twalpole commented Jun 11, 2014

@jnicklas The real issue with this is that HaveSelector needs to catch the Capybara::ExpectationNotMet exception and then ends up raising an RSpec::Expectations::ExpectationNotMetError exception. This may necessitate waiting for a major version update if there was a guarantee of HaveSelector raising Capybara::ExpecationNotMet on failure. I don't see it documented (or specifically tested) anywhere. What would your thoughts on it be?

Collaborator

abotalov commented Jun 11, 2014

I think it should be done in major version.

Collaborator

abotalov commented Jun 11, 2014

It wasn't documented but it's a quiet well known (and reliable) fact that those methods raise Capybara::ExpectationNotMet error - http://stackoverflow.com/search?q=%5Bcapybara%5D+ExpectationNotMet

Collaborator

abotalov commented Jun 11, 2014

Also as this is backwards incompatible change please take a look on jnicklas#1246 as it refactors this code too (I know that I should rebase it, maybe fix something, include Composable, etc.)

Collaborator

twalpole commented Jun 11, 2014

@abotalov all of the entries I looked at in that search were people trying to figure out why their matcher was failing, none of them seemed to be people rescuing that specific exception. I'm not convinced this needs to go into a major release.

twalpole merged commit 8d1fea1 into master Jun 12, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details

Is there a release cycle for capybara, wondering when this will make it into the gem?

Collaborator

twalpole commented Jun 13, 2014

@DaveBlooman There is no fixed release cycle. I'm aiming for the next release in 1-2 weeks

Thanks for update and the PR.

I think there should be attr_reader, not attr_accessor. Master hasn't been released yet so I think it's OK to make this public API change.

twalpole deleted the compound_matchers branch Aug 26, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment