Skip to main content

Simple http server for API mocking during automated testing

Project description

Simple http server for API mocking during automated testing

Example usage

Using requests library:

>>> import requests
>>> from httpsrv import Server
>>> server = Server(8080).start()
>>> server.on('GET', '/').text('hello')
>>> res = requests.get('http://localhost:8080')
>>> assert res.text == 'hello'


pip install httpsrv

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for httpsrv, version 0.1.6
Filename, size File type Python version Upload date Hashes
Filename, size httpsrv-0.1.6-py3-none-any.whl (5.8 kB) File type Wheel Python version 3.5 Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page