Comments (5)
So, I put together my own patch which adds this support - however - it's certainly not for mainline use as it is specific to httpclient + soap4r at the moment: http://gist.github.com/206226
However, it raised the interesting idea of abstracting the generated Net::HTTPResponse object to fit other libraries. In this case, I had to extend the response to carry status
and content
methods. It may be more useful to have a custom response object come back through FakeWeb.response_for
, in most cases the current Net::HTTP-like object, but for httpclient, for instance, a slightly modified version. If that were available, I wouldn't have had to monkey with Net::HTTPHeader and HTTPClient in this patch.
Just a thought.
from fakeweb.
Note to self, httpclient is now on github. http://github.com/nahi/httpclient
from fakeweb.
implemented the patch in a branch on my fork:
http://github.com/woahdae/fakeweb/commit/a45da6465ec12de5ccf6976e9245fcac8476e07f
working in tests relying on soap4r
from fakeweb.
(would have sent a pull request, but didn't want to write tests and don't know how to make it generic)
from fakeweb.
Hey guys, I just runned into the same issue. I need to mock soap4r gem and it uses httpclient. I found this thread, that points to a fork which has the specific changes to fake httpclient, but it seems a bit older (January 05, 2009)..
http://groups.google.com/group/fakeweb-users/browse_thread/thread/7893b121c7c2414f/7309c3b6d7a5fe9c
Do you guys have any news about it?
Thanks!
from fakeweb.
Related Issues (20)
- 1.3.0 does not recognize registered uri for post method
- FakeWeb stops @javascript (capybara & selenium) cukes from running. HOT 22
- Assigned but unused variable - uri in lib/fake_web/utility.rb:35
- using an https url HOT 2
- FakeWeb doesn't mimic Net::HTTP's check "#read_body called twice (IOError)"
- Different Responses to the same URI based on the passed data HOT 2
- "FakeWeb.allow_net_connect = true" doesn't work with PORO/ElasticSearch
- FakeWeb doesn't match non alphabetized query strings
- consider switching to Mocha 1.0 HOT 1
- please tag a new version and release a new gem HOT 4
- Unregister single URIs
- NetConnectNotAllowedError reports the URI different than what is acually being matched. HOT 3
- FakeWeb post method and check the request.body
- Too many connections error
- Release is desperately needed HOT 19
- Make it easier to access submitted data HOT 1
- Compatibility Issue with Ruby 2.4? HOT 2
- Test failures? HOT 4
- Regexp with query params fail without trailing slash after host
- Ruby 2 stops receiving security updates at the end of March
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fakeweb.