diff --git a/README.rst b/README.rst index e4f4b47d..d7499fa6 100644 --- a/README.rst +++ b/README.rst @@ -80,6 +80,11 @@ Django project. For further installation information see `docs/install.html` and `docs/configuration.html` +Testing +------- + +See quicktest.py for usage details + Upgrading from previous versions -------------------------------- @@ -111,3 +116,4 @@ We're happy to include any type of contribution! This can be: For more information on contributing, please see the `CONTRIBUTING.rst` file. .. _note: http://docs.djangoproject.com/en/dev/ref/databases/#sqlite-string-matching + diff --git a/helpdesk/tests/test_get_email.py b/helpdesk/tests/test_get_email.py index 2efd7a15..eba4572b 100644 --- a/helpdesk/tests/test_get_email.py +++ b/helpdesk/tests/test_get_email.py @@ -708,7 +708,10 @@ class GetEmailCCHandling(TestCase): # build matrix of test cases case_methods = [c[0] for c in Queue._meta.get_field('email_box_type').choices] -case_socks = [False] + [c[0] for c in Queue._meta.get_field('socks_proxy_type').choices] + +# uncomment if you want to run tests with socks - which is much slover +# case_socks = [False] + [c[0] for c in Queue._meta.get_field('socks_proxy_type').choices] +case_socks = [False] case_matrix = list(itertools.product(case_methods, case_socks)) # Populate TestCases from the matrix of parameters diff --git a/quicktest.py b/quicktest.py index 2ed332ee..07b12a26 100644 --- a/quicktest.py +++ b/quicktest.py @@ -1,3 +1,10 @@ +""" +Usage: +$ python -m venv .venv +$ source .venv/bin/activate +$ pip install -r requirements-testing.txt -r requirements.txt +$ python ./quicktest.py +""" import os import sys import argparse @@ -65,7 +72,6 @@ class QuickDjangoTest(object): }, ] - def __init__(self, *args, **kwargs): self.tests = args self._tests() @@ -102,6 +108,7 @@ class QuickDjangoTest(object): if failures: sys.exit(failures) + if __name__ == '__main__': """ What do when the user hits this file from the shell.