{ "info": { "author": "Timofey Kukushkin", "author_email": "tima@kukushkin.me", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Plugins", "Framework :: Pytest", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Topic :: Software Development :: Libraries :: Python Modules", "Topic :: Software Development :: Testing" ], "description": "# pytest-describe-it\n\n[![PyPI version](https://badge.fury.io/py/pytest-describe-it.svg)](https://pypi.org/project/pytest-describe-it/) ![PyPI - Python Version](https://img.shields.io/pypi/pyversions/pytest-describe-it.svg?color=green) [![Build Status](https://travis-ci.org/tkukushkin/pytest-describe-it.svg?branch=master)](https://travis-ci.org/tkukushkin/pytest-describe-it)\n\n## Example\n\nSome simple test:\n```python\nimport pytest\n\n\ndef add(x: int, y: int) -> int:\n return x + y\n\n\n@pytest.mark.describe('add')\nclass TestAdd:\n\n @pytest.mark.parametrize(['x', 'y', 'expected'], [\n (1, 2, 3),\n (3, 4, 7),\n (5, 6, 10),\n ])\n @pytest.mark.it('returns {expected} for add({x}, {y})')\n def test_add(self, x, y, expected):\n assert add(x, y) == expected\n\n```\n\nPytest output:\n```python\ncollected 3 items\n\ntest_add.py ..F [100%]\n\n====================================== FAILURES =======================================\n________________ TestAdd.test_add[[ add \u2014 returns 10 for add(5, 6) ]] _________________\n\nself = , x = 5, y = 6, expected = 10\n\n @pytest.mark.parametrize(['x', 'y', 'expected'], [\n (1, 2, 3),\n (3, 4, 7),\n (5, 6, 10),\n ])\n @pytest.mark.it('returns {expected} for add({x}, {y})')\n def test_add(self, x, y, expected):\n> assert add(x, y) == expected\nE assert 11 == 10\nE + where 11 = add(5, 6)\n\ntest_add.py:18: AssertionError\n========================= 1 failed, 2 passed in 0.05 seconds ==========================\n```\n\nWith pytest-sugar:\n```python\ncollecting ...\n test_add.py \u2713\u2713 67% \u2588\u2588\u2588\u2588\u2588\u2588\u258b\n\n\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015 TestAdd.test_add[[ add \u2014 returns 10 for add(5, 6) ]] \u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\u2015\n\nself = , x = 5, y = 6, expected = 10\n\n @pytest.mark.parametrize(['x', 'y', 'expected'], [\n (1, 2, 3),\n (3, 4, 7),\n (5, 6, 10),\n ])\n @pytest.mark.it('returns {expected} for add({x}, {y})')\n def test_add(self, x, y, expected):\n> assert add(x, y) == expected\nE assert 11 == 10\nE + where 11 = add(5, 6)\n\ntest_add.py:18: AssertionError\n\n test_add.py \u2a2f 100% \u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\n\nResults (0.10s):\n 2 passed\n 1 failed\n - test_add.py:11 TestAdd.test_add[[ add \u2014 returns 10 for add(5, 6) ]]\n```\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/tkukushkin/pytest-describe-it", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "pytest-describe-it", "package_url": "https://pypi.org/project/pytest-describe-it/", "platform": "", "project_url": "https://pypi.org/project/pytest-describe-it/", "project_urls": { "Homepage": "https://github.com/tkukushkin/pytest-describe-it", "Source": "https://github.com/tkukushkin/pytest-describe-it" }, "release_url": "https://pypi.org/project/pytest-describe-it/0.1.0/", "requires_dist": [ "pytest", "typing ; python_version < \"3\"", "pycodestyle ; extra == 'test'" ], "requires_python": "", "summary": "plugin for rich text descriptions", "version": "0.1.0" }, "last_serial": 5558130, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "a51791f7fc8f87a26e7edd1c0f9340a8", "sha256": "102b14cdeea668eff089d706e03698b518d53174d2e1aed3c55c0e70a7ed7cf3" }, "downloads": -1, "filename": "pytest_describe_it-0.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "a51791f7fc8f87a26e7edd1c0f9340a8", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 4327, "upload_time": "2019-07-19T19:41:30", "url": "https://files.pythonhosted.org/packages/e2/43/a09d78e6eb9a1d469b7bcd40ca4cbecb9d1188ee7e66ca3edfb649a722bd/pytest_describe_it-0.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "1e8634d2b93fa253b78d4967ec157fcf", "sha256": "58789035ea73dce10253630c33de9b3afa2e3af320239bab137f2b7c9cb90a37" }, "downloads": -1, "filename": "pytest-describe-it-0.1.0.tar.gz", "has_sig": false, "md5_digest": "1e8634d2b93fa253b78d4967ec157fcf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3045, "upload_time": "2019-07-19T19:41:32", "url": "https://files.pythonhosted.org/packages/3e/d3/3568eb89155be2917d504cba84d2d7c68e691a9b525b15d8263d9f4f6273/pytest-describe-it-0.1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "a51791f7fc8f87a26e7edd1c0f9340a8", "sha256": "102b14cdeea668eff089d706e03698b518d53174d2e1aed3c55c0e70a7ed7cf3" }, "downloads": -1, "filename": "pytest_describe_it-0.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "a51791f7fc8f87a26e7edd1c0f9340a8", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 4327, "upload_time": "2019-07-19T19:41:30", "url": "https://files.pythonhosted.org/packages/e2/43/a09d78e6eb9a1d469b7bcd40ca4cbecb9d1188ee7e66ca3edfb649a722bd/pytest_describe_it-0.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "1e8634d2b93fa253b78d4967ec157fcf", "sha256": "58789035ea73dce10253630c33de9b3afa2e3af320239bab137f2b7c9cb90a37" }, "downloads": -1, "filename": "pytest-describe-it-0.1.0.tar.gz", "has_sig": false, "md5_digest": "1e8634d2b93fa253b78d4967ec157fcf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3045, "upload_time": "2019-07-19T19:41:32", "url": "https://files.pythonhosted.org/packages/3e/d3/3568eb89155be2917d504cba84d2d7c68e691a9b525b15d8263d9f4f6273/pytest-describe-it-0.1.0.tar.gz" } ] }