Skip to content
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

WebMock is on globally now; no need to disable it #208

Merged
merged 2 commits into from Dec 2, 2014

Conversation

pd
Copy link
Contributor

@pd pd commented Dec 2, 2014

Introduced by conflicts in how #175 and #196 juggled webmock usage.

Closes #207.

Introduced by conflicts in how voxpupuli#175 and voxpupuli#196 juggled webmock usage.

Closes voxpupuli#207.
@iainbeeston
Copy link
Contributor

Ah I see - that's because of me.

👍

@pd
Copy link
Contributor Author

pd commented Dec 2, 2014

Eek, still some errors for the other JSON backends. Will figure it out soon.

@iainbeeston
Copy link
Contributor

Each json backend has it’s own parsing error classes - they all inherit from standard error though (I had the same problem when writing tests to check initialize_data, across different backends)=

@iainbeeston
Copy link
Contributor

Incidentally, I put in place a “refute_block” helper method in the initialize_data test - that might help you (and I meant to move it into test_helper.rb, so it could be reused, but never did)=

@pd
Copy link
Contributor Author

pd commented Dec 2, 2014

I'm not thrilled with how I just dealt with it in f263094, but I really did want the test to be fairly explicit about "the JSON parse error should be allowed to bubble up", not just "something could raise here". Checking for the currently defined modules is the best I could come up with ... =\

@RST-J
Copy link
Contributor

RST-J commented Dec 2, 2014

If someone has a better idea some time we can change that then.
👍

@iainbeeston
Copy link
Contributor

Actually, that’s not bad - can you put that in test_helper? Perhaps rename it as “assert_raises_parse_error”? I’d like to reuse it in a test I wrote for initialize_data=

@iainbeeston
Copy link
Contributor

Tell you what, I'll refactor both.

Merging

iainbeeston added a commit that referenced this pull request Dec 2, 2014
WebMock is on globally now; no need to disable it
@iainbeeston iainbeeston merged commit de5ab73 into voxpupuli:master Dec 2, 2014
@pd pd deleted the leave-webmock-enabled branch December 2, 2014 22:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants