METADATA 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. Metadata-Version: 2.0
  2. Name: httpretty
  3. Version: 0.9.6
  4. Summary: HTTP client mock for Python
  5. Home-page: https://httpretty.readthedocs.io
  6. Author: Gabriel Falcao
  7. Author-email: gabriel@nacaolivre.org
  8. License: MIT
  9. Platform: UNKNOWN
  10. Classifier: Development Status :: 5 - Production/Stable
  11. Classifier: Intended Audience :: Developers
  12. Classifier: License :: OSI Approved :: MIT License
  13. Classifier: Programming Language :: Python :: 2
  14. Classifier: Programming Language :: Python :: 2.7
  15. Classifier: Programming Language :: Python :: 3
  16. Classifier: Programming Language :: Python :: 3.6
  17. Classifier: Programming Language :: Python :: 3.7
  18. Classifier: Programming Language :: Python
  19. Classifier: Topic :: Internet :: WWW/HTTP
  20. Classifier: Topic :: Software Development :: Testing
  21. Requires-Dist: six
  22. HTTPretty 0.9.6
  23. ===============
  24. HTTP Client mocking tool for Python. Provides a full fake TCP socket module. Inspired by `FakeWeb <https://github.com/chrisk/fakeweb>`_
  25. - `Github Repository <https://github.com/gabrielfalcao/HTTPretty>`_
  26. - `Documentation <https://httpretty.readthedocs.io/en/latest/>`_
  27. - `PyPI Package <https://pypi.org/project/httpretty/>`_
  28. **Python Support:**
  29. - **2.7.13**
  30. - **3.6.5**
  31. .. image:: https://github.com/gabrielfalcao/HTTPretty/raw/master/docs/source/_static/logo.svg?sanitize=true
  32. .. image:: https://readthedocs.org/projects/httpretty/badge/?version=latest
  33. :target: http://httpretty.readthedocs.io/en/latest/?badge=latest
  34. :alt: Documentation Status
  35. .. image:: https://travis-ci.org/gabrielfalcao/HTTPretty.svg?branch=master
  36. :target: https://travis-ci.org/gabrielfalcao/HTTPretty
  37. .. |PyPI python versions| image:: https://img.shields.io/pypi/pyversions/HTTPretty.svg
  38. :target: https://pypi.python.org/pypi/HTTPretty
  39. .. |Join the chat at https://gitter.im/gabrielfalcao/HTTPretty| image:: https://badges.gitter.im/gabrielfalcao/HTTPretty.svg
  40. :target: https://gitter.im/gabrielfalcao/HTTPretty?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
  41. Install
  42. -------
  43. .. code:: bash
  44. pip install httpretty
  45. Common Use Cases
  46. ================
  47. - Test-driven development of API integrations
  48. - Fake responses of external APIs
  49. - Record and playback HTTP requests
  50. Simple Example
  51. --------------
  52. .. code:: python
  53. import sure
  54. import httpretty
  55. import requests
  56. @httpretty.activate
  57. def test_httpbin():
  58. httpretty.register_uri(
  59. httpretty.GET,
  60. "https://httpbin.org/ip",
  61. body='{"origin": "127.0.0.1"}'
  62. )
  63. response = requests.get('https://httpbin.org/ip')
  64. response.json().should.equal({'origin': '127.0.0.1'})
  65. License
  66. =======
  67. ::
  68. <HTTPretty - HTTP client mock for Python>
  69. Copyright (C) <2011-2018> Gabriel Falcão <gabriel@nacaolivre.org>
  70. Permission is hereby granted, free of charge, to any person
  71. obtaining a copy of this software and associated documentation
  72. files (the "Software"), to deal in the Software without
  73. restriction, including without limitation the rights to use,
  74. copy, modify, merge, publish, distribute, sublicense, and/or sell
  75. copies of the Software, and to permit persons to whom the
  76. Software is furnished to do so, subject to the following
  77. conditions:
  78. The above copyright notice and this permission notice shall be
  79. included in all copies or substantial portions of the Software.
  80. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  81. EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
  82. OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
  83. NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
  84. HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
  85. WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
  86. FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
  87. OTHER DEALINGS IN THE SOFTWARE.
  88. Main contributors
  89. =================
  90. HTTPretty has received `many contributions <https://github.com/gabrielfalcao/HTTPretty/graphs/contributors>`_
  91. but some folks made remarkable contributions and deserve extra credit:
  92. - Andrew Gross ~> `@andrewgross <https://github.com/andrewgross>`_
  93. - Hugh Saunders ~> `@hughsaunders <https://github.com/hughsaunders>`_
  94. - James Rowe ~> `@JNRowe <https://github.com/JNRowe>`_
  95. - Matt Luongo ~> `@mhluongo <https://github.com/mhluongo>`_
  96. - Steve Pulec ~> `@spulec <https://github.com/spulec>`_
  97. - Miro Hrončok ~> `@hroncok <https://github.com/hroncok>`_