<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">Hi! Need to get the community to weigh in on this…<div><br></div><div>In Neutron there currently is no mock library for the Requests package. During Icehouse, I created unit tests that used the httmock package (a context-library based Requests mock). However, the community did not want me to add this to global requirements, because there was httpretty (a URL registration based mock) already approved for use (but not in Neutron). As a result, I disabled the UTs (renaming the module to have a “no” prefix).</div><div><br></div><div>Instead of modifying the UT to work with httpretty, and requesting that httpretty be added to Neutron test-requirements, I waited, as there was discussion on replacing httpretty.</div><div><br></div><div>Fast forward to now, and there is a new requests-mock package that has been implemented, added to global requirements, and is being used in keystone client and nova client projects. My goal is to make use of the new mock library, as it has become the library of choice.</div><div><br></div><div>I have migrated my UT to use the requests-mock package, and would like to gain approval to add requests-mock to Neutron. I have two commits out for review. The first, <a href="https://review.openstack.org/#/c/115107/">https://review.openstack.org/#/c/115107/</a>, is to add requests-mock to test-requirements for Neutron. The second,<a href="https://review.openstack.org/#/c/116018">https://review.openstack.org/#/c/116018</a>/, has the UT module reworked to use requests-mock, AND includes the addition of requests-mock to test-requirements (so that there is one commit showing the use of this new library - originally, I had just the UT, but there was a request to join the two changes).</div><div><br></div><div><b>Community questions:</b></div><div><b><br></b></div><div><b>Is it OK to add requests-mock to Neutron test-requirements?</b></div><div><b>If so, would you rather see this done as two commits (one for the package, one for the UT), or one combined commit?</b></div><div><b><br></b></div><div><b>Cores, you can “vote/comment” in the reviews, so that I can proceed in the right direction.</b></div><div><br></div><div>Thanks for your consideration!</div><div><br></div><div><br></div><div><div apple-content-edited="true">
<div><div>PCM (Paul Michali)</div><div><br></div><div>MAIL …..…. <a href="mailto:pcm@cisco.com">pcm@cisco.com</a></div><div>IRC ……..… pcm_ (<a href="http://irc.freenode.com">irc.freenode.com</a>)</div><div>TW ………... @pmichali</div><div>GPG Key … 4525ECC253E31A83</div><div>Fingerprint .. 307A 96BB 1A4C D2C7 931D 8D2D 4525 ECC2 53E3 1A83</div></div><div><br></div><br class="Apple-interchange-newline">
</div>
<br></div></body></html>