Skip to main content

Object-Oriented HTTP Request

Project description

winney

pypi Codacy Badge

Install

pip install winney

Tutorial

from winney import Winney
from winney.mock import Mock


class MockData(Mock):
    data = {"name": "baidu.com"}


baidu = Winney(host="baidu.com")
baidu.register(method="get",
                name="get_home",
                uri="/home",
                mock=True,
                mock_data=MockData())
r = baidu.get_home()
print(r.json())

Project details


Download files

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

Source Distribution

winney-0.5.3.tar.gz (4.8 kB view hashes)

Uploaded Source

Built Distribution

winney-0.5.3-py3-none-any.whl (5.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page