estately / rets

A pure-ruby library for fetching data from RETS servers
https://github.com/estately/rets
127 stars 94 forks source link

RFC Create mock http client to avoid partial stubbing #189

Closed hfaulds closed 8 years ago

hfaulds commented 8 years ago

Motivated by https://github.com/estately/rets/pull/188

The partial stubbing in our tests was hiding an exception.

I wanted to try using some dependency injection and real objects to help make our tests capture these scenarios.

hfaulds commented 8 years ago

So I guess my real aim is to remove any instance of client.stub from the tests.

I don't feel this PR is very focused on making that a reality but thought I'd share my ideas publicly. I'll close this and hopefully find some time to address this properly in another PR.