{ "info": { "author": "Krzysztof Warunek", "author_email": "krzysztof@warunek.net", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7" ], "description": "aiounittest\n===========\n\n|image0|_ |image1|_\n\n.. |image0| image:: https://api.travis-ci.org/kwarunek/aiounittest.png?branch=master\n.. _image0: https://travis-ci.org/kwarunek/aiounittest\n\n.. |image1| image:: https://badge.fury.io/py/aiounittest.svg\n.. _image1: https://badge.fury.io/py/aiounittest\n\nInfo\n====\n\nThis is a helper library to ease of your pain (and boilerplate), when writing a test of the asynchronous code (:code:`asyncio`). You can test:\n\n* synchronous code (same as the :code:`unittest.TestCase`)\n* asynchronous code, it supports syntax with :code:`async`/:code:`await` (Python 3.5+) and :code:`asyncio.coroutine`/:code:`yield from` (Python 3.4)\n\n \nInstallation\n============\n\nUse pip:\n\n::\n\n pip install aiounittest\n\n \nUsage\n=====\n\nIt's as simple as use of :code:`unittest.TestCase`. Full docs at http://aiounittest.readthedocs.io.\n\n.. code-block:: python\n\n import asyncio\n import aiounittest\n\n\n async def add(x, y):\n await asyncio.sleep(0.1)\n return x + y\n\n class MyTest(aiounittest.AsyncTestCase):\n\n async def test_async_add(self):\n ret = await add(5, 6)\n self.assertEqual(ret, 11)\n\n # or 3.4 way\n @asyncio.coroutine\n def test_sleep(self):\n ret = yield from add(5, 6)\n self.assertEqual(ret, 11)\n\n # some regular test code\n def test_something(self):\n self.assertTrue(true)\n\nLibrary provide some additional tooling:\n\n* async_test_,\n* AsyncMockIterator_ to mock object for `async for`,\n* futurized_ to mock coroutines.\n\n.. _futurized: http://aiounittest.readthedocs.io/en/latest/futurized.html\n.. _async_test: http://aiounittest.readthedocs.io/en/latest/async_test.html\n.. _AsyncMockIterator: http://aiounittest.readthedocs.io/en/latest/asyncmockiterator.html\n\nLicense\n=======\n\nMIT", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/kwarunek/aiounittest", "keywords": "asyncio,async,unittest,coroutine", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "aiounittest", "package_url": "https://pypi.org/project/aiounittest/", "platform": "", "project_url": "https://pypi.org/project/aiounittest/", "project_urls": { "Homepage": "https://github.com/kwarunek/aiounittest" }, "release_url": "https://pypi.org/project/aiounittest/1.3.0/", "requires_dist": null, "requires_python": "", "summary": "Test asyncio code more easily.", "version": "1.3.0" }, "last_serial": 5733506, "releases": { "1.0.1": [ { "comment_text": "", "digests": { "md5": "6092bfbcdeb99aa45a336b16ba936007", "sha256": "16cd5340cd0d2c71485d1bc8342edb3ccaa079a62b3bc219c51e1bda3d2255fc" }, "downloads": -1, "filename": "aiounittest-1.0.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "6092bfbcdeb99aa45a336b16ba936007", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 6759, "upload_time": "2017-08-17T23:48:35", "url": "https://files.pythonhosted.org/packages/f4/c6/f64e7d2ac6da20c04a905c5965a9ca0f1f59912d17ad5bf05ee7b16be82a/aiounittest-1.0.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "2b60a354e570852740dc4eca9a82d334", "sha256": "94187839bac0986bf4ab6d23361d354edc9551d42d9108c7587bae0abaa28623" }, "downloads": -1, "filename": "aiounittest-1.0.1.tar.gz", "has_sig": false, "md5_digest": "2b60a354e570852740dc4eca9a82d334", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4771, "upload_time": "2017-08-17T23:48:36", "url": "https://files.pythonhosted.org/packages/9b/cc/2890c8fa4815b42b3762fa39199f1361eeb5e15cac92c400ddd2691312dd/aiounittest-1.0.1.tar.gz" } ], "1.1.0": [ { "comment_text": "", "digests": { "md5": "ff12a1ff5f0d2739ff64b375230c7f7c", "sha256": "110351d49e748231813da958ab1ef921924720f03ab34db4a0677a7973ebc20d" }, "downloads": -1, "filename": "aiounittest-1.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "ff12a1ff5f0d2739ff64b375230c7f7c", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 6399, "upload_time": "2017-08-20T23:25:24", "url": "https://files.pythonhosted.org/packages/e1/59/d7314ee7509f50fa1fdc6c4f4644cfc10c8428af23be88dad0ddf5fe07c5/aiounittest-1.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "381676a95185136a9d7b316bf4208d41", "sha256": "226970365eeb4b90c7408091d91e9455acf39d8140125c2e42c49c81c7d2bf64" }, "downloads": -1, "filename": "aiounittest-1.1.0.tar.gz", "has_sig": false, "md5_digest": "381676a95185136a9d7b316bf4208d41", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4691, "upload_time": "2017-08-20T23:25:25", "url": "https://files.pythonhosted.org/packages/72/34/46c4512e9ea32b68941a87ecf871545b17d8c7b5362b62d7d2d6a7a553be/aiounittest-1.1.0.tar.gz" } ], "1.2.0": [ { "comment_text": "", "digests": { "md5": "75879a94e5713fedb3c6b28740bf77ab", "sha256": "13d355aa36a26143ce27f19921bf986935bf6742bc62ff99498ca994547b9964" }, "downloads": -1, "filename": "aiounittest-1.2.0.tar.gz", "has_sig": false, "md5_digest": "75879a94e5713fedb3c6b28740bf77ab", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5199, "upload_time": "2019-06-11T14:32:27", "url": "https://files.pythonhosted.org/packages/83/76/dd14d849c82439d230d54d49a166508a38d485d65428c8b5d4b3ff6f3fd7/aiounittest-1.2.0.tar.gz" } ], "1.2.1": [ { "comment_text": "", "digests": { "md5": "19b6285276686f6e5ef16da8d6b2c3c5", "sha256": "68ef9f35169544fd81454c754b34d5a05049fd864ae645c003ffb60ccc74a203" }, "downloads": -1, "filename": "aiounittest-1.2.1.tar.gz", "has_sig": false, "md5_digest": "19b6285276686f6e5ef16da8d6b2c3c5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5313, "upload_time": "2019-06-11T17:14:34", "url": "https://files.pythonhosted.org/packages/d5/c3/c6093d13eaf509f683eea3661ad6ba5cfd429095b07295243122c1b6cea8/aiounittest-1.2.1.tar.gz" } ], "1.3.0": [ { "comment_text": "", "digests": { "md5": "8d5d407b232afb981252ec9d45eb346e", "sha256": "e847482b85c2b01fa8c99ffc9606811257448899707b7c7ec06e0f11c019603f" }, "downloads": -1, "filename": "aiounittest-1.3.0.tar.gz", "has_sig": false, "md5_digest": "8d5d407b232afb981252ec9d45eb346e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5362, "upload_time": "2019-08-26T22:19:22", "url": "https://files.pythonhosted.org/packages/58/d8/dec59fa116f6402b634b63878ee69d95e4d9af1b80bd0ea2828f85fac3e9/aiounittest-1.3.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "8d5d407b232afb981252ec9d45eb346e", "sha256": "e847482b85c2b01fa8c99ffc9606811257448899707b7c7ec06e0f11c019603f" }, "downloads": -1, "filename": "aiounittest-1.3.0.tar.gz", "has_sig": false, "md5_digest": "8d5d407b232afb981252ec9d45eb346e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5362, "upload_time": "2019-08-26T22:19:22", "url": "https://files.pythonhosted.org/packages/58/d8/dec59fa116f6402b634b63878ee69d95e4d9af1b80bd0ea2828f85fac3e9/aiounittest-1.3.0.tar.gz" } ] }