Commit Graph

223 Commits

Author SHA1 Message Date
Alex Seeholzer
f7f0882f86 Merge branch 'master-upstream' into django-1.9-fixes
* master-upstream:
  Fix QueueMembership bug revealed by django.test's DiscoverRunner
2015-11-18 10:16:33 +01:00
Alex Seeholzer
307e9446a2 ensure tests for ticket submission run correctly in django 1.9 (URI's no longer include the scheme and domain part of the URLs) 2015-11-16 16:08:52 +01:00
Jonathan Barratt
0610a6645d Fix QueueMembership bug revealed by django.test's DiscoverRunner
If HELPDESK_ENABLE_PER_QUEUE_STAFF_MEMBERSHIP was True but a user had
no QueueMembership entries, then restricting queue access generated
RelatedObjectDoesNotExist exceptions.

 - Ask for forgiveness whenever we try to limit a queryset by the
queuemembership related object set.

 - Since tests can now be run with the project's settings active,
rather than only with quicktest.py's settings, restore the initial
HELPDESK_ENABLE_PER_QUEUE_MEMBERSHIP value after having tested the
related functionality.
2015-11-16 18:45:27 +07:00
Alex Seeholzer
cd0daccb56 tests are correctly discovered for django < 1.6 2015-11-13 15:35:36 +01:00
Alex Seeholzer
50877c3708 Trying to fix travis build error & more general test imports: all files with test_*.py are imported from the /tests directory; 2015-11-13 14:07:36 +01:00
Scott Sadler
2681f6340c fix reload_urlconf test helper so it supports a third party urlconf 2015-11-06 15:22:44 +01:00
Scott Sadler
e82c17567a Merge branch 'master' into django-1.8
Conflicts:
	helpdesk/tests/__init__.py
2015-11-06 14:50:33 +01:00
Alex Seeholzer
f9682ccf37 renamed test __init__.py imports to new test naming scheme 2015-06-12 15:52:35 +02:00
Alex Seeholzer
da30d2b973 tests renamed for compliance 2015-06-12 15:48:38 +02:00
Jonathan Barratt
bfcd8fc024 Add ability to restrict users' access by queue if so configured, and migration and tests for same. 2015-06-12 12:23:39 +07:00
Simon Thépot
83affccec5 Specify features to load in failing testcase for django < 1.7 2015-01-14 16:00:35 +01:00
Tom Graham
d2ac8af6c0 Improved support for custom user models
Support for custom user models with a non-standard username field
2014-10-22 16:18:04 +11:00
Stefano Brentegani
4ed8f11754 merge HELPDESK_CUSTOM_STAFF_FILTER_CALLBACK into HELPDESK_ALLOW_NON_STAFF_TICKET_UPDATE 2014-08-01 07:20:43 +02:00
Stefano Brentegani
14d7279844 test non-public update by non-staff user is blocked 2014-07-30 06:55:43 +02:00
Stefano Brentegani
c0dd6ea075 test helpdesk.views.staff.return_to_ticket 2014-07-30 06:07:08 +02:00
Stefano Brentegani
ccec263452 Also test is_helpdesk_staff 2014-07-29 22:41:09 +02:00
Stefano Brentegani
82df965d5f replace HELPDESK_ALLOW_NON_STAFF_TICKET_UPDATE in homepage view and test behaviour 2014-07-29 22:03:47 +02:00
Stefano Brentegani
581e43a3b0 separate authorisation function from decorator 2014-07-29 20:55:25 +02:00
Stefano Brentegani
aea940cb3f move decorators to their own module, rename to helpdesk_* 2014-07-28 11:46:02 +02:00
Stefano Brentegani
97c317f83d add tests, example 2014-07-28 06:47:19 +02:00
Stefano Brentegani
fe5c7135a6 exclude KB from navigation if HELPDESK_KB_ENABLED is False (fixes #223) 2014-07-21 18:44:54 +02:00
Ross Poulton
11aeee8ad5 Improve public action tests 2012-08-08 14:32:17 +10:00
Ross Poulton
26e0809e5e Add some tests. Finally. First draft: just includes submission & public
action testing - needs plenty more tests added.
2012-08-08 00:04:34 +10:00