{ "info": { "author": "Igor `idle sign` Starikov", "author_email": "idlesign@yandex.ru", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Framework :: Pytest", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Topic :: Software Development :: Testing" ], "description": "pytest-stub\n===========\nhttps://github.com/idlesign/pytest-stub\n\n|release| |lic| |ci| |coverage| |health|\n\n.. |release| image:: https://img.shields.io/pypi/v/pytest-stub.svg\n :target: https://pypi.python.org/pypi/pytest-stub\n\n.. |lic| image:: https://img.shields.io/pypi/l/pytest-stub.svg\n :target: https://pypi.python.org/pypi/pytest-stub\n\n.. |ci| image:: https://img.shields.io/travis/idlesign/pytest-stub/master.svg\n :target: https://travis-ci.org/idlesign/pytest-stub\n\n.. |coverage| image:: https://img.shields.io/coveralls/idlesign/pytest-stub/master.svg\n :target: https://coveralls.io/r/idlesign/pytest-stub\n\n.. |health| image:: https://landscape.io/github/idlesign/pytest-stub/master/landscape.svg?style=flat\n :target: https://landscape.io/github/idlesign/pytest-stub/master\n\n\n\nDescription\n-----------\n\n*Stub packages, modules and attributes.*\n\nThis pytest plugin allows you to replace dependencies with stubs.\n\nIt can be useful if you want to test some code using a dependency without actually having this dependency,\nfor example if you're testing your library, which uses some parts of another library.\n\n\nRequirements\n------------\n\n* Python 3\n* pytest >= 2.9.0\n\n\nHow to use\n----------\n\nUse ``stub`` fixture in your test functions, like this:\n\n.. code-block:: python\n\n def test_django_related(stub):\n\n stub.apply({\n # Replace `call_command` with a generated function.\n 'django.core.management.call_command': '[func]',\n\n # Replace `BaseCommand` with a generated class.\n 'django.core.management.base.BaseCommand': '[cls]',\n\n # Stub multiple attributes in the same module with custom objects.\n 'django.conf': {\n 'settings': object(),\n 'some': True,\n },\n\n })\n\n\nYou can stub dependencies either with your own custom objects or you may instruct ``pytest-stub``\nto generate functions or classes for you.\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/idlesign/pytest-stub", "keywords": "", "license": "BSD 3-Clause License", "maintainer": "", "maintainer_email": "", "name": "pytest-stub", "package_url": "https://pypi.org/project/pytest-stub/", "platform": "", "project_url": "https://pypi.org/project/pytest-stub/", "project_urls": { "Homepage": "https://github.com/idlesign/pytest-stub" }, "release_url": "https://pypi.org/project/pytest-stub/0.1.0/", "requires_dist": null, "requires_python": "", "summary": "Stub packages, modules and attributes.", "version": "0.1.0" }, "last_serial": 4640893, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "f00baf3c27164ebd92e4528223bcffb0", "sha256": "0d5ecfaa01cc3682a3292b112e9c2d0223de69a43b29502b7568cb4e3c6635a5" }, "downloads": -1, "filename": "pytest_stub-0.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "f00baf3c27164ebd92e4528223bcffb0", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 5501, "upload_time": "2018-12-28T12:37:58", "url": "https://files.pythonhosted.org/packages/3b/6c/ab2ef432045e223b4cf424aa40ca04f4835a788c5aef27d82d9896b06a8f/pytest_stub-0.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "05a0dcea0c12051cf6eaf5be76e9ae93", "sha256": "849f9c8007e68b542b96db833037749a49e9d66c413a01dc5302510e62202d5e" }, "downloads": -1, "filename": "pytest-stub-0.1.0.tar.gz", "has_sig": false, "md5_digest": "05a0dcea0c12051cf6eaf5be76e9ae93", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5068, "upload_time": "2018-12-28T12:37:55", "url": "https://files.pythonhosted.org/packages/da/e4/dbce55853783e57b752d0b845ae560ce5b4a3f78519fce7efe3b05ec17e4/pytest-stub-0.1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "f00baf3c27164ebd92e4528223bcffb0", "sha256": "0d5ecfaa01cc3682a3292b112e9c2d0223de69a43b29502b7568cb4e3c6635a5" }, "downloads": -1, "filename": "pytest_stub-0.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "f00baf3c27164ebd92e4528223bcffb0", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 5501, "upload_time": "2018-12-28T12:37:58", "url": "https://files.pythonhosted.org/packages/3b/6c/ab2ef432045e223b4cf424aa40ca04f4835a788c5aef27d82d9896b06a8f/pytest_stub-0.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "05a0dcea0c12051cf6eaf5be76e9ae93", "sha256": "849f9c8007e68b542b96db833037749a49e9d66c413a01dc5302510e62202d5e" }, "downloads": -1, "filename": "pytest-stub-0.1.0.tar.gz", "has_sig": false, "md5_digest": "05a0dcea0c12051cf6eaf5be76e9ae93", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5068, "upload_time": "2018-12-28T12:37:55", "url": "https://files.pythonhosted.org/packages/da/e4/dbce55853783e57b752d0b845ae560ce5b4a3f78519fce7efe3b05ec17e4/pytest-stub-0.1.0.tar.gz" } ] }