{ "info": { "author": "Jakub STOLARSKI (Dryobates)", "author_email": "jakub.stolarski@kidosoft.pl", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Web Environment", "Framework :: Django", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Utilities" ], "description": "#########\nSmarttest\n#########\n\n.. image:: https://pypip.in/wheel/django-smarttest/badge.svg\n :target: https://pypi.python.org/pypi/django-smarttest/\n :alt: Wheel Status\n\n.. image:: https://pypip.in/version/django-smarttest/badge.svg\n :target: https://pypi.python.org/pypi/django-smarttest/\n :alt: Latest Version\n\n.. image:: https://pypip.in/license/django-smarttest/badge.svg\n :target: https://pypi.python.org/pypi/django-smarttest/\n :alt: License\n\n\nGoal\n====\n\nProvide code snippets which help running tests in Django.\n\nInstallation\n============\n\nInstall requirements:\n\n.. code-block:: console\n \n pip install -r requirements.txt\n\nInstall Smarttest:\n\n.. code-block:: console\n\n pip install django-smarttest\n\nor current development version:\n\n.. code-block:: console\n\n pip install hg+https:://bitbucket.org/kidosoft/django-smarttest\n\nConfiguration\n=============\n\n.. code-block:: python\n\n INSTALLED_APPS = [\n ...\n 'smarttest',\n ...\n ]\n\nUsage\n=====\n\nPreventing tests from touching database\n---------------------------------------\n\n.. code-block:: python\n\n import unittest\n\n from smarttest.decorators import no_db_testcase\n\n @no_db_testcase\n class SomeTestCase(unittest.TestCase):\n\n def test_some_test(self):\n ...\n\nIf you'll accidentally write code that tries to run some query on database\nyou'll get exception.\n\nRunning only selected test types\n--------------------------------\n\n.. code-block:: python\n\n import unittest\n\n from smarttest.decorators import test_type\n\n @test_type('acceptance')\n class SomeAcceptanceTestCase(unittest.TestCase):\n\n def test_some_acceptance_test(self):\n ...\n\n @test_type('unit')\n class SomeUnitTestCase(unittest.TestCase):\n\n def test_some_unit_test(self):\n ...\n\n class UnspecifiedTypeTestCase(unittest.TestCase):\n\n def test_some_test(self):\n ...\n\n.. code-block:: python\n\n $ python -m unittest script\n ...\n ----------------------------------------------------------------------\n Ran 3 tests in 0.000s\n\n OK\n $ IGNORE_TESTS=unit python -m unittest script \n .s.\n ----------------------------------------------------------------------\n Ran 3 tests in 0.000s\n\n OK (skipped=1)\n $ IGNORE_TESTS=acceptance python -m unittest script \n s..\n ----------------------------------------------------------------------\n Ran 3 tests in 0.000s\n\n OK (skipped=1)\n $ IGNORE_TESTS=acceptance,unit python -m unittest script \n ss.\n ----------------------------------------------------------------------\n Ran 3 tests in 0.000s\n\n OK (skipped=2)\n\n\nTest type can be any selected word. It doesn't have to be \"unit\" or \"acceptance\". You can have different test types for running in different environments if you need.\n\nTestCase for use with switchable splinter driver\n------------------------------------------------\n\nSimple TestCase that allows for simple switching between different drivers\nin tests.\n\nIn settings.py:\n\n.. code-block:: python\n\n TEST_DRIVER = 'firefox' # or django or any other\n\n\nIn test:\n\n.. code-block:: python\n\n from smarttest.testcases import SplinterTestCase\n\n class SomeTestCase(SplinterTestCase):\n\n def test_some_test(self):\n self.browser.visit(self.get_host() + '/')\n\n\nIf you run tests continuously (e.g. doing Test Driven Development)\nTEST_DRIVER='django' (default setting) is the fastest driver that do not\ninterrupt your workflow. However when you run your acceptance tests you may want\nto check how it behaves with real browser. Simply set TEST_DRIVER='firefox'\nor any other real browser supported by splinter.\n\n\nSupported Django versions\n=========================\n\nTested with: \n\n* Django 1.2.7 on python2.7\n* Django 1.3.7 on python2.7\n* Django 1.4.16 on python2.7\n* Django 1.5.11 on python2.7, python3.3, python3.4\n* Django 1.6.8 on python2.7, python3.3, python3.4\n* Django 1.7.1 on python2.7, python3.3, python3.4\n\nDocumentation\n=============\n\nhttp://kidosoft.pl/docs/django-smarttest/", "description_content_type": null, "docs_url": null, "download_url": null, "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://kidosoft.pl", "keywords": "django testing", "license": "beerware", "maintainer": null, "maintainer_email": null, "name": "django-smarttest", "package_url": "https://pypi.org/project/django-smarttest/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-smarttest/", "project_urls": { "Homepage": "http://kidosoft.pl" }, "release_url": "https://pypi.org/project/django-smarttest/0.3.0/", "requires_dist": null, "requires_python": null, "summary": "Code snippets which help writing automated tests for Django.", "version": "0.3.0" }, "last_serial": 1908921, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "5bd30aa020dc3bd9f9c9b91badc34cf8", "sha256": "a8ced00f6c8c473ab1e5c6a19d5f3b234e167c882076254a2baf1b244ae74c7c" }, "downloads": -1, "filename": "django_smarttest-0.1.0-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "5bd30aa020dc3bd9f9c9b91badc34cf8", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 9372, "upload_time": "2014-12-01T19:07:23", "url": "https://files.pythonhosted.org/packages/3d/72/f1c14d341a3858ac979949b889f18a08b1c028847e84c839b997d8e2bb0c/django_smarttest-0.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "9598cd809f6f964ec427799a226db07d", "sha256": "2de9d292d815bca0ea6af06dd655ec75d52ea7727fb151eaa0eb5871ff4764da" }, "downloads": -1, "filename": "django-smarttest-0.1.0.tar.gz", "has_sig": true, "md5_digest": "9598cd809f6f964ec427799a226db07d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7366, "upload_time": "2014-12-01T19:07:20", "url": "https://files.pythonhosted.org/packages/02/a9/dacc26a6b51b314dc44ca3a1fe2c73ca7279f42a4e5f4728b702ee904e80/django-smarttest-0.1.0.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "1836f328a233c963b652f60548518beb", "sha256": "0cde8b05a8a95dbc704c029633716a02b34abfd5b0a3ba564493582fccf35f94" }, "downloads": -1, "filename": "django_smarttest-0.2.1-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "1836f328a233c963b652f60548518beb", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 11278, "upload_time": "2015-03-29T18:20:50", "url": "https://files.pythonhosted.org/packages/28/5d/8f8e53bdac9f846749cea7c752a4443ce79e3ea1d1bd641bb32daab4405b/django_smarttest-0.2.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "94bdabcdc1c6cf0f2114372340f72184", "sha256": "bf99549c75b6863c25c27b16bd1256448460ab6b8d4b5f91710610826c8c0b1d" }, "downloads": -1, "filename": "django-smarttest-0.2.1.tar.gz", "has_sig": true, "md5_digest": "94bdabcdc1c6cf0f2114372340f72184", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8684, "upload_time": "2015-03-29T18:20:47", "url": "https://files.pythonhosted.org/packages/74/9e/3cc6615ed2bf8e9bd006514c9baec8a88baca96deca2cf5a5e16ea62cb4e/django-smarttest-0.2.1.tar.gz" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "d62bc639f45736d91a7f39e2921b4a5c", "sha256": "63d02e53284ab86531d0bc7ee311b6c90d0e02883c7e8bd91a79c7d358066dbe" }, "downloads": -1, "filename": "django_smarttest-0.3.0-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "d62bc639f45736d91a7f39e2921b4a5c", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 12539, "upload_time": "2016-01-17T19:58:52", "url": "https://files.pythonhosted.org/packages/24/7e/06147f396bf884372f05388022e876e278da9d989d1c815b14a858f34f95/django_smarttest-0.3.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "03aaeb98615be5a8249e66d77d8266e9", "sha256": "e29c332df13fcad695f543943d04c805a3332e8258bc72ab4c57f4dc1db30863" }, "downloads": -1, "filename": "django-smarttest-0.3.0.tar.gz", "has_sig": true, "md5_digest": "03aaeb98615be5a8249e66d77d8266e9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9490, "upload_time": "2016-01-17T19:58:48", "url": "https://files.pythonhosted.org/packages/b2/7a/ea03a024de779642d72026a9cc51bc320f9ee34ac963a24d58020fc20ce4/django-smarttest-0.3.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "d62bc639f45736d91a7f39e2921b4a5c", "sha256": "63d02e53284ab86531d0bc7ee311b6c90d0e02883c7e8bd91a79c7d358066dbe" }, "downloads": -1, "filename": "django_smarttest-0.3.0-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "d62bc639f45736d91a7f39e2921b4a5c", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 12539, "upload_time": "2016-01-17T19:58:52", "url": "https://files.pythonhosted.org/packages/24/7e/06147f396bf884372f05388022e876e278da9d989d1c815b14a858f34f95/django_smarttest-0.3.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "03aaeb98615be5a8249e66d77d8266e9", "sha256": "e29c332df13fcad695f543943d04c805a3332e8258bc72ab4c57f4dc1db30863" }, "downloads": -1, "filename": "django-smarttest-0.3.0.tar.gz", "has_sig": true, "md5_digest": "03aaeb98615be5a8249e66d77d8266e9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9490, "upload_time": "2016-01-17T19:58:48", "url": "https://files.pythonhosted.org/packages/b2/7a/ea03a024de779642d72026a9cc51bc320f9ee34ac963a24d58020fc20ce4/django-smarttest-0.3.0.tar.gz" } ] }