Mercurial > hg > savane-forge
changeset 356:c05f52b49a3c
Base fixtures for trackers (bugs only) + 1 test for svpeople/jobs
author | Sylvain Beucler <beuc@beuc.net> |
---|---|
date | Sun, 31 Oct 2010 21:59:24 +0100 |
parents | 8e07641c425e |
children | 596c4bbbce02 |
files | savane/svpeople/forms.py savane/svpeople/tests.py savane/tracker/fixtures/fieldchoice.yaml savane/tracker/fixtures/fieldoverlay.yaml savane/tracker/tests.py |
diffstat | 5 files changed, 825 insertions(+), 25 deletions(-) [+] |
line wrap: on
line diff
--- a/savane/svpeople/forms.py +++ b/savane/svpeople/forms.py @@ -20,6 +20,7 @@ from django import forms import django.contrib.auth.models as auth_models import models as svpeople_models +from django.utils.translation import ugettext from django.utils.translation import ugettext as _ class JobForm(forms.ModelForm):
--- a/savane/svpeople/tests.py +++ b/savane/svpeople/tests.py @@ -1,23 +1,31 @@ -""" -This file demonstrates two different styles of tests (one doctest and one -unittest). These will both pass when you run "manage.py test". - -Replace these with more appropriate tests for your application. -""" +# Jobs tests +# Copyright (C) 2010 Sylvain Beucler +# +# This file is part of Savane. +# +# Savane is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# Savane is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. from django.test import TestCase +from django.core.urlresolvers import reverse class SimpleTest(TestCase): - def test_basic_addition(self): - """ - Tests that 1 + 1 always equals 2. - """ - self.failUnlessEqual(1 + 1, 2) + fixtures = [ + ] -__test__ = {"doctest": """ -Another way to test that 1 + 1 is equal to 2. - ->>> 1 + 1 == 2 -True -"""} - + def test_010_view_job(self): + """ + Create a job + """ + response = self.client.get(reverse('savane:svpeople:job_detail', args=(1,))) + self.assertEqual(response.status_code, 200)
new file mode 100644 --- /dev/null +++ b/savane/tracker/fixtures/fieldchoice.yaml @@ -0,0 +1,334 @@ +# Only the 'bugs' tracker for now +- fields: {description: The bug has been submitted, email_ad: null, field: status_id, + group: null, rank: 20, send_all_flag: true, status: P, tracker: bugs, value: Open, + value_id: 1} + model: tracker.fieldchoice + pk: 1 +- fields: {description: The bug is no longer active. See the Resolution field for + details on how it was resolved., email_ad: null, field: status_id, group: null, + rank: 400, send_all_flag: true, status: P, tracker: bugs, value: Closed, value_id: 3} + model: tracker.fieldchoice + pk: 2 +- fields: {description: Issue which is mainly a matter of taste, email_ad: null, field: severity, + group: null, rank: 10, send_all_flag: true, status: A, tracker: bugs, value: 1 + - Wish, value_id: 1} + model: tracker.fieldchoice + pk: 3 +- fields: {description: '', email_ad: null, field: severity, group: null, rank: 20, + send_all_flag: true, status: H, tracker: bugs, value: '1,5', value_id: 2} + model: tracker.fieldchoice + pk: 4 +- fields: {description: 'Issue which doesn''t affect the object''s usefulness, and + is presumably trivial to handle', email_ad: null, field: severity, group: null, + rank: 30, send_all_flag: true, status: A, tracker: bugs, value: 2 - Minor, value_id: 3} + model: tracker.fieldchoice + pk: 5 +- fields: {description: '', email_ad: null, field: severity, group: null, rank: 40, + send_all_flag: true, status: H, tracker: bugs, value: '2,5', value_id: 4} + model: tracker.fieldchoice + pk: 6 +- fields: {description: '', email_ad: null, field: severity, group: null, rank: 50, + send_all_flag: true, status: A, tracker: bugs, value: 3 - Normal, value_id: 5} + model: tracker.fieldchoice + pk: 7 +- fields: {description: '', email_ad: null, field: severity, group: null, rank: 60, + send_all_flag: true, status: H, tracker: bugs, value: '3,5', value_id: 6} + model: tracker.fieldchoice + pk: 8 +- fields: {description: 'Issue which has a major effect on the usability of the object, + without rendering it completely unusable to everyone', email_ad: null, field: severity, + group: null, rank: 70, send_all_flag: true, status: A, tracker: bugs, value: 4 + - Important, value_id: 7} + model: tracker.fieldchoice + pk: 9 +- fields: {description: 'Issue which makes the object in question unusable or mostly + so, or causes data loss', email_ad: null, field: severity, group: null, rank: 80, + send_all_flag: true, status: A, tracker: bugs, value: 5 - Blocker, value_id: 8} + model: tracker.fieldchoice + pk: 10 +- fields: {description: Issue which introduces a security breach, email_ad: null, + field: severity, group: null, rank: 90, send_all_flag: true, status: A, tracker: bugs, + value: 6 - Security, value_id: 9} + model: tracker.fieldchoice + pk: 11 +- fields: {description: '', email_ad: null, field: category_id, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 12 +- fields: {description: '', email_ad: null, field: bug_group_id, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 13 +- fields: {description: This item is already covered by another item, email_ad: null, + field: resolution_id, group: null, rank: 120, send_all_flag: true, status: A, + tracker: bugs, value: Duplicate, value_id: 7} + model: tracker.fieldchoice + pk: 14 +- fields: {description: No problem found for the project team, email_ad: null, field: resolution_id, + group: null, rank: 60, send_all_flag: true, status: A, tracker: bugs, value: Works + For Me, value_id: 6} + model: tracker.fieldchoice + pk: 15 +- fields: {description: 'This field is a deprecated duplicate of Postponed, existing + only for historical reason', email_ad: null, field: resolution_id, group: null, + rank: 60, send_all_flag: true, status: H, tracker: bugs, value: Remind, value_id: 5} + model: tracker.fieldchoice + pk: 16 +- fields: {description: The issue will be handled later, email_ad: null, field: resolution_id, + group: null, rank: 80, send_all_flag: true, status: A, tracker: bugs, value: Postponed, + value_id: 4} + model: tracker.fieldchoice + pk: 17 +- fields: {description: More information is need to be able to handle this item, email_ad: null, + field: resolution_id, group: null, rank: 90, send_all_flag: true, status: A, tracker: bugs, + value: Need Info, value_id: 8} + model: tracker.fieldchoice + pk: 18 +- fields: {description: The issue won't be fixed (see comments), email_ad: null, field: resolution_id, + group: null, rank: 40, send_all_flag: true, status: A, tracker: bugs, value: Wont + Fix, value_id: 3} + model: tracker.fieldchoice + pk: 19 +- fields: {description: This item is not valid for some reason (see comments), email_ad: null, + field: resolution_id, group: null, rank: 130, send_all_flag: true, status: A, + tracker: bugs, value: Invalid, value_id: 2} + model: tracker.fieldchoice + pk: 20 +- fields: {description: '', email_ad: null, field: category_version_id, group: null, + rank: 10, send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 21 +- fields: {description: '', email_ad: null, field: platform_version_id, group: null, + rank: 10, send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 22 +- fields: {description: '', email_ad: null, field: reproducibility_id, group: null, + rank: 10, send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 23 +- fields: {description: '', email_ad: null, field: reproducibility_id, group: null, + rank: 20, send_all_flag: true, status: P, tracker: bugs, value: Every Time, value_id: 110} + model: tracker.fieldchoice + pk: 24 +- fields: {description: '', email_ad: null, field: reproducibility_id, group: null, + rank: 30, send_all_flag: true, status: P, tracker: bugs, value: Intermittent, + value_id: 120} + model: tracker.fieldchoice + pk: 25 +- fields: {description: '', email_ad: null, field: reproducibility_id, group: null, + rank: 40, send_all_flag: true, status: P, tracker: bugs, value: Once, value_id: 130} + model: tracker.fieldchoice + pk: 26 +- fields: {description: '', email_ad: null, field: size_id, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 27 +- fields: {description: '', email_ad: null, field: size_id, group: null, rank: 20, + send_all_flag: true, status: A, tracker: bugs, value: Low <30, value_id: 110} + model: tracker.fieldchoice + pk: 28 +- fields: {description: '', email_ad: null, field: size_id, group: null, rank: 30, + send_all_flag: true, status: A, tracker: bugs, value: Medium 30 - 200, value_id: 120} + model: tracker.fieldchoice + pk: 29 +- fields: {description: '', email_ad: null, field: size_id, group: null, rank: 40, + send_all_flag: true, status: A, tracker: bugs, value: High >200, value_id: 130} + model: tracker.fieldchoice + pk: 30 +- fields: {description: '', email_ad: null, field: fix_release_id, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 31 +- fields: {description: '', email_ad: null, field: comment_type_id, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 32 +- fields: {description: '', email_ad: null, field: plan_release_id, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 33 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 10, + send_all_flag: true, status: A, tracker: bugs, value: 1 - Later, value_id: 1} + model: tracker.fieldchoice + pk: 34 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 20, + send_all_flag: true, status: A, tracker: bugs, value: '2', value_id: 2} + model: tracker.fieldchoice + pk: 35 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 30, + send_all_flag: true, status: A, tracker: bugs, value: 3 - Low, value_id: 3} + model: tracker.fieldchoice + pk: 36 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 40, + send_all_flag: true, status: A, tracker: bugs, value: '4', value_id: 4} + model: tracker.fieldchoice + pk: 37 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 50, + send_all_flag: true, status: A, tracker: bugs, value: 5 - Normal, value_id: 5} + model: tracker.fieldchoice + pk: 38 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 60, + send_all_flag: true, status: A, tracker: bugs, value: '6', value_id: 6} + model: tracker.fieldchoice + pk: 39 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 70, + send_all_flag: true, status: A, tracker: bugs, value: 7 - High, value_id: 7} + model: tracker.fieldchoice + pk: 40 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 80, + send_all_flag: true, status: A, tracker: bugs, value: '8', value_id: 8} + model: tracker.fieldchoice + pk: 41 +- fields: {description: '', email_ad: null, field: priority, group: null, rank: 90, + send_all_flag: true, status: A, tracker: bugs, value: 9 - Immediate, value_id: 9} + model: tracker.fieldchoice + pk: 42 +- fields: {description: '', email_ad: null, field: release_id, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 43 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 1, send_all_flag: true, status: A, tracker: bugs, value: 0%, value_id: 1} + model: tracker.fieldchoice + pk: 44 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 10, send_all_flag: true, status: A, tracker: bugs, value: 10%, value_id: 10} + model: tracker.fieldchoice + pk: 45 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 20, send_all_flag: true, status: A, tracker: bugs, value: 20%, value_id: 20} + model: tracker.fieldchoice + pk: 46 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 30, send_all_flag: true, status: A, tracker: bugs, value: 30%, value_id: 30} + model: tracker.fieldchoice + pk: 47 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 40, send_all_flag: true, status: A, tracker: bugs, value: 40%, value_id: 40} + model: tracker.fieldchoice + pk: 48 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 50, send_all_flag: true, status: A, tracker: bugs, value: 50%, value_id: 50} + model: tracker.fieldchoice + pk: 49 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 60, send_all_flag: true, status: A, tracker: bugs, value: 60%, value_id: 60} + model: tracker.fieldchoice + pk: 50 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 70, send_all_flag: true, status: A, tracker: bugs, value: 70%, value_id: 70} + model: tracker.fieldchoice + pk: 51 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 80, send_all_flag: true, status: A, tracker: bugs, value: 80%, value_id: 80} + model: tracker.fieldchoice + pk: 52 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 90, send_all_flag: true, status: A, tracker: bugs, value: 90%, value_id: 90} + model: tracker.fieldchoice + pk: 53 +- fields: {description: '', email_ad: null, field: percent_complete, group: null, + rank: 100, send_all_flag: true, status: A, tracker: bugs, value: 100%, value_id: 100} + model: tracker.fieldchoice + pk: 54 +- fields: {description: '', email_ad: null, field: resolution_id, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 56 +- fields: {description: '', email_ad: null, field: platform_version_id, group: null, + rank: 50, send_all_flag: true, status: A, tracker: bugs, value: Mac OS, value_id: 140} + model: tracker.fieldchoice + pk: 58 +- fields: {description: The bug was resolved, email_ad: null, field: resolution_id, + group: null, rank: 30, send_all_flag: true, status: A, tracker: bugs, value: Fixed, + value_id: 1} + model: tracker.fieldchoice + pk: 59 +- fields: {description: '', email_ad: null, field: platform_version_id, group: null, + rank: 20, send_all_flag: true, status: A, tracker: bugs, value: GNU/Linux, value_id: 110} + model: tracker.fieldchoice + pk: 60 +- fields: {description: '', email_ad: null, field: platform_version_id, group: null, + rank: 30, send_all_flag: true, status: A, tracker: bugs, value: Microsoft Windows, + value_id: 120} + model: tracker.fieldchoice + pk: 61 +- fields: {description: '', email_ad: null, field: platform_version_id, group: null, + rank: 40, send_all_flag: true, status: A, tracker: bugs, value: '*BSD', value_id: 130} + model: tracker.fieldchoice + pk: 62 +- fields: {description: '', email_ad: null, field: custom_sb1, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 620 +- fields: {description: '', email_ad: null, field: custom_sb2, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 621 +- fields: {description: '', email_ad: null, field: custom_sb3, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 622 +- fields: {description: '', email_ad: null, field: custom_sb4, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 623 +- fields: {description: '', email_ad: null, field: custom_sb5, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 624 +- fields: {description: '', email_ad: null, field: custom_sb6, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 625 +- fields: {description: '', email_ad: null, field: custom_sb7, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 626 +- fields: {description: '', email_ad: null, field: custom_sb8, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 627 +- fields: {description: '', email_ad: null, field: custom_sb9, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 628 +- fields: {description: '', email_ad: null, field: custom_sb10, group: null, rank: 10, + send_all_flag: true, status: P, tracker: bugs, value: None, value_id: 100} + model: tracker.fieldchoice + pk: 629 +- fields: {description: This item can be seen by everybody., email_ad: null, field: privacy, + group: null, rank: 10, send_all_flag: true, status: A, tracker: bugs, value: Public, + value_id: 1} + model: tracker.fieldchoice + pk: 3108 +- fields: {description: This item can be seen only by project members., email_ad: null, + field: privacy, group: null, rank: 20, send_all_flag: true, status: A, tracker: bugs, + value: Private, value_id: 2} + model: tracker.fieldchoice + pk: 3109 +- fields: {description: This item is currently being worked on, email_ad: null, field: resolution_id, + group: null, rank: 70, send_all_flag: true, status: A, tracker: bugs, value: In + Progress, value_id: 9} + model: tracker.fieldchoice + pk: 3431 +- fields: {description: This item should be tested now, email_ad: null, field: resolution_id, + group: null, rank: 65, send_all_flag: true, status: A, tracker: bugs, value: Ready + For Test, value_id: 10} + model: tracker.fieldchoice + pk: 3432 +- fields: {description: The issue is confirmed, email_ad: null, field: resolution_id, + group: null, rank: 82, send_all_flag: true, status: A, tracker: bugs, value: Confirmed, + value_id: 11} + model: tracker.fieldchoice + pk: 3460 +- fields: {description: Comment can be added freely, email_ad: null, field: discussion_lock, + group: null, rank: 20, send_all_flag: true, status: P, tracker: bugs, value: Unlocked, + value_id: 0} + model: tracker.fieldchoice + pk: 4251 +- fields: {description: Discussion about this item is over, email_ad: null, field: discussion_lock, + group: null, rank: 30, send_all_flag: true, status: P, tracker: bugs, value: Locked, + value_id: 1} + model: tracker.fieldchoice + pk: 4252
new file mode 100644 --- /dev/null +++ b/savane/tracker/fixtures/fieldoverlay.yaml @@ -0,0 +1,445 @@ +# Only the 'bugs' tracker for now +- fields: {description: '', display_size: '', empty_ok: null, field: percent_complete, + group: null, keep_history: true, label: Percent Complete, rank: 500, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: false} + model: tracker.fieldoverlay + pk: 1 +- fields: {description: User who originally submitted the item, display_size: '', + empty_ok: null, field: submitted_by, group: null, keep_history: false, label: Submitted + by, rank: 20, show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: false, + tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 2 +- fields: {description: Date and time of the initial submission, display_size: 10/15, + empty_ok: null, field: date, group: null, keep_history: false, label: Submitted + on, rank: 40, show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: false, + tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 3 +- fields: {description: Date and time when the item status was changed to 'Closed', + display_size: 10/15, empty_ok: null, field: close_date, group: null, keep_history: false, + label: Closed on, rank: 50, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 4 +- fields: {description: 'Most basic status of the item: is the item considered as + dealt with or not.', display_size: '', empty_ok: null, field: status_id, group: null, + keep_history: true, label: Open/Closed, rank: 600, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: true} + model: tracker.fieldoverlay + pk: 5 +- fields: {description: 'Impact of the item on the system (Critical, Major,...)', + display_size: '', empty_ok: null, field: severity, group: null, keep_history: true, + label: Severity, rank: 200, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: true, tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 6 +- fields: {description: 'Generally high level modules or functionalities of the software + (e.g. User interface, Configuration Manager, etc)', display_size: '', empty_ok: null, + field: category_id, group: null, keep_history: true, label: Category, rank: 100, + show_on_add_anonymous: false, show_on_add_connected: true, show_on_add_members: true, + tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 7 +- fields: {description: Who is in charge of handling this item, display_size: '', + empty_ok: null, field: assigned_to, group: null, keep_history: true, label: Assigned + to, rank: 500, show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: true, + tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 8 +- fields: {description: One line description of the item, display_size: 65/120, empty_ok: null, + field: summary, group: null, keep_history: true, label: Summary, rank: 700000, + show_on_add_anonymous: false, show_on_add_connected: true, show_on_add_members: true, + tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 9 +- fields: {description: Full description of the item, display_size: 65/20, empty_ok: null, + field: details, group: null, keep_history: true, label: Original Submission, rank: 700001, + show_on_add_anonymous: false, show_on_add_connected: true, show_on_add_members: true, + tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 10 +- fields: {description: 'Characterizes the nature of the item (e.g. Crash Error, Documentation + Typo, Installation Problem, etc', display_size: '', empty_ok: null, field: bug_group_id, + group: null, keep_history: true, label: Item Group, rank: 300, show_on_add_anonymous: false, + show_on_add_connected: true, show_on_add_members: true, tracker: bugs, transition_default_auth: A, + use_it: true} + model: tracker.fieldoverlay + pk: 11 +- fields: {description: Current status of the item, display_size: '', empty_ok: null, + field: resolution_id, group: null, keep_history: true, label: Status, rank: 400, + show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: true, + tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 12 +- fields: {description: Version of the System Component (aka Item Category) impacted + by the item, display_size: '', empty_ok: null, field: category_version_id, group: null, + keep_history: true, label: Component Version, rank: 1000, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: false} + model: tracker.fieldoverlay + pk: 13 +- fields: {description: Operating System impacted by the issue, display_size: '', + empty_ok: null, field: platform_version_id, group: null, keep_history: true, label: Operating + System, rank: 1100, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 14 +- fields: {description: How easy it is to reproduce the item, display_size: '', empty_ok: null, + field: reproducibility_id, group: null, keep_history: true, label: Reproducibility, + rank: 1200, show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: false, + tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 15 +- fields: {description: Estimated size of the code to be developed or reworked to + fix the item, display_size: '', empty_ok: null, field: size_id, group: null, + keep_history: true, label: Size (loc), rank: 1300, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: false} + model: tracker.fieldoverlay + pk: 16 +- fields: {description: Release in which the item was actually fixed, display_size: '', + empty_ok: null, field: fix_release_id, group: null, keep_history: true, label: Fixed + Release, rank: 1400, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 17 +- fields: {description: Specify the nature of the follow up comment attached to this + item, display_size: '', empty_ok: null, field: comment_type_id, group: null, + keep_history: false, label: Comment Type, rank: 1500, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: true} + model: tracker.fieldoverlay + pk: 18 +- fields: {description: Number of hours of work needed to fix the item, display_size: 5/5, + empty_ok: null, field: hours, group: null, keep_history: true, label: Effort, + rank: 1700, show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: false, + tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 19 +- fields: {description: Release in which it is planned to have the item fixed, display_size: '', + empty_ok: null, field: plan_release_id, group: null, keep_history: true, label: Planned + Release, rank: 1600, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 20 +- fields: {description: Version of the system component (or work product) impacted + by the item (<u>in free text</u>), display_size: 10/40, empty_ok: null, field: component_version, + group: null, keep_history: true, label: Component Version, rank: 1800, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: false} + model: tracker.fieldoverlay + pk: 21 +- fields: {description: Release in which the bug was actually fixed (<u>in free text</u>), + display_size: 10/40, empty_ok: null, field: fix_release, group: null, keep_history: true, + label: Fixed Release, rank: 1900, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 22 +- fields: {description: Release in which it is planned to have the item fixed (<u>in + free text</u>), display_size: 10/40, empty_ok: null, field: plan_release, group: null, + keep_history: true, label: Planned Release, rank: 2000, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: false} + model: tracker.fieldoverlay + pk: 23 +- fields: {description: How quickly the item should be handled, display_size: '', + empty_ok: null, field: priority, group: null, keep_history: true, label: Priority, + rank: 250, show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: false, + tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 24 +- fields: {description: Unique item identifier, display_size: 6/10, empty_ok: null, + field: bug_id, group: null, keep_history: false, label: Item ID, rank: 10, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: true} + model: tracker.fieldoverlay + pk: 25 +- fields: {description: Unique project identifier, display_size: '', empty_ok: null, + field: group_id, group: null, keep_history: false, label: Group ID, rank: 30, + show_on_add_anonymous: false, show_on_add_connected: true, show_on_add_members: true, + tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 26 +- fields: {description: List of comma separated keywords associated with this item, + display_size: 60/120, empty_ok: null, field: keywords, group: null, keep_history: true, + label: Keywords, rank: 3000, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 27 +- fields: {description: Release (global version number) impacted by the item, display_size: '', + empty_ok: null, field: release_id, group: null, keep_history: true, label: Release, + rank: 800, show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: false, + tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 28 +- fields: {description: Release (global version number) impacted by the item (<u>in + free text</u>), display_size: 10/40, empty_ok: null, field: release, group: null, + keep_history: true, label: Release, rank: 800, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 29 +- fields: {description: Name of the person who submitted the item (if different from + the submitter field), display_size: 20/40, empty_ok: null, field: originator_name, + group: null, keep_history: true, label: Originator Name, rank: 550, show_on_add_anonymous: false, + show_on_add_connected: false, show_on_add_members: false, tracker: bugs, transition_default_auth: A, + use_it: false} + model: tracker.fieldoverlay + pk: 30 +- fields: {description: 'Email address of the person who submitted the item (if different + from the submitter field, add address to CC list)', display_size: 20/40, empty_ok: null, + field: originator_email, group: null, keep_history: true, label: Originator Email, + rank: 560, show_on_add_anonymous: false, show_on_add_connected: false, show_on_add_members: false, + tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 31 +- fields: {description: Phone number of the person who submitted the item, display_size: 10/40, + empty_ok: null, field: originator_phone, group: null, keep_history: true, label: Originator + Phone, rank: 570, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 32 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf1, group: null, keep_history: true, + label: 'Custom Text Field #1', rank: 30000, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 33 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf2, group: null, keep_history: true, + label: 'Custom Text Field #2', rank: 30100, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 34 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf3, group: null, keep_history: true, + label: 'Custom Text Field #3', rank: 30200, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 35 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf4, group: null, keep_history: true, + label: 'Custom Text Field #4', rank: 30300, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 36 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf5, group: null, keep_history: true, + label: 'Custom Text Field #5', rank: 30400, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 37 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf6, group: null, keep_history: true, + label: 'Custom Text Field #6', rank: 30500, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 38 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf7, group: null, keep_history: true, + label: 'Custom Text Field #7', rank: 30600, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 39 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf8, group: null, keep_history: true, + label: 'Custom Text Field #8', rank: 30700, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 40 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf9, group: null, keep_history: true, + label: 'Custom Text Field #9', rank: 30800, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 41 +- fields: {description: 'Customizable Text Field (one line, up to 255 characters', + display_size: 10/15, empty_ok: null, field: custom_tf10, group: null, keep_history: true, + label: 'Custom Text Field #10', rank: 30900, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 42 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta1, group: null, keep_history: true, label: 'Custom + Text Area #1', rank: 40000, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 43 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta2, group: null, keep_history: true, label: 'Custom + Text Area #2', rank: 40100, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 44 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta3, group: null, keep_history: true, label: 'Custom + Text Area #3', rank: 40200, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 45 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta4, group: null, keep_history: true, label: 'Custom + Text Area #4', rank: 40300, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 46 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta5, group: null, keep_history: true, label: 'Custom + Text Area #5', rank: 40400, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 47 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta6, group: null, keep_history: true, label: 'Custom + Text Area #6', rank: 40500, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 48 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta7, group: null, keep_history: true, label: 'Custom + Text Area #7', rank: 40600, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 49 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta8, group: null, keep_history: true, label: 'Custom + Text Area #8', rank: 40700, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 50 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta9, group: null, keep_history: true, label: 'Custom + Text Area #9', rank: 40800, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 51 +- fields: {description: Customizable Text Area (multi-line text), display_size: 60/3, + empty_ok: null, field: custom_ta10, group: null, keep_history: true, label: 'Custom + Text Area #10', rank: 40900, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 52 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb1, group: null, keep_history: true, + label: 'Custom Select Box #1', rank: 50000, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 53 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb2, group: null, keep_history: true, + label: 'Custom Select Box #2', rank: 50100, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 54 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb3, group: null, keep_history: true, + label: 'Custom Select Box #3', rank: 50200, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 55 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb4, group: null, keep_history: true, + label: 'Custom Select Box #4', rank: 50300, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 56 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb5, group: null, keep_history: true, + label: 'Custom Select Box #5', rank: 50400, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 57 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb6, group: null, keep_history: true, + label: 'Custom Select Box #6', rank: 50500, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 58 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb7, group: null, keep_history: true, + label: 'Custom Select Box #7', rank: 50600, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 59 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb8, group: null, keep_history: true, + label: 'Custom Select Box #8', rank: 50700, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 60 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb9, group: null, keep_history: true, + label: 'Custom Select Box #9', rank: 50800, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 61 +- fields: {description: Customizable Select Box (pull down menu with predefined values), + display_size: '', empty_ok: null, field: custom_sb10, group: null, keep_history: true, + label: 'Custom Select Box #10', rank: 50900, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 62 +- fields: {description: Customizable Date Field, display_size: 10/10, empty_ok: null, + field: custom_df1, group: null, keep_history: true, label: 'Custom Date Field + #1', rank: 60000, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 63 +- fields: {description: Customizable Date Field, display_size: 10/10, empty_ok: null, + field: custom_df2, group: null, keep_history: true, label: 'Custom Date Field + #2', rank: 60100, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 64 +- fields: {description: Customizable Date Field, display_size: 10/10, empty_ok: null, + field: custom_df3, group: null, keep_history: true, label: 'Custom Date Field + #3', rank: 60200, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 65 +- fields: {description: Customizable Date Field, display_size: 10/10, empty_ok: null, + field: custom_df4, group: null, keep_history: true, label: 'Custom Date Field + #4', rank: 60300, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 66 +- fields: {description: Customizable Date Field, display_size: 10/10, empty_ok: null, + field: custom_df5, group: null, keep_history: true, label: 'Custom Date Field + #5', rank: 60400, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 67 +- fields: {description: Determines whether the item can be seen by members of the + project only or anybody., display_size: '', empty_ok: null, field: privacy, + group: null, keep_history: true, label: Privacy, rank: 402, show_on_add_anonymous: false, + show_on_add_connected: true, show_on_add_members: true, tracker: bugs, transition_default_auth: A, + use_it: true} + model: tracker.fieldoverlay + pk: 68 +- fields: {description: How many votes this item received., display_size: 6/10, empty_ok: null, + field: vote, group: null, keep_history: false, label: Votes, rank: 405, show_on_add_anonymous: false, + show_on_add_connected: true, show_on_add_members: true, tracker: bugs, transition_default_auth: A, + use_it: true} + model: tracker.fieldoverlay + pk: 69 +- fields: {description: Determines whether comments can still be added to the item, + display_size: '', empty_ok: null, field: discussion_lock, group: null, keep_history: true, + label: Discussion Lock, rank: 800, show_on_add_anonymous: false, show_on_add_connected: false, + show_on_add_members: false, tracker: bugs, transition_default_auth: A, use_it: true} + model: tracker.fieldoverlay + pk: 70 +- fields: {description: Date and time when someone should start working on the item, + display_size: 10/15, empty_ok: null, field: planned_starting_date, group: null, + keep_history: true, label: Should Start On, rank: 55, show_on_add_anonymous: false, + show_on_add_connected: true, show_on_add_members: true, tracker: bugs, transition_default_auth: A, + use_it: false} + model: tracker.fieldoverlay + pk: 71 +- fields: {description: Date and time when the item should be completed, display_size: 10/15, + empty_ok: null, field: planned_close_date, group: null, keep_history: true, label: Should + be Finished on, rank: 56, show_on_add_anonymous: false, show_on_add_connected: true, + show_on_add_members: true, tracker: bugs, transition_default_auth: A, use_it: false} + model: tracker.fieldoverlay + pk: 72
--- a/savane/tracker/tests.py +++ b/savane/tracker/tests.py @@ -1,9 +1,20 @@ -""" -This file demonstrates two different styles of tests (one doctest and one -unittest). These will both pass when you run "manage.py test". - -Replace these with more appropriate tests for your application. -""" +# Trackers tests +# Copyright (C) 2010 Sylvain Beucler +# +# This file is part of Savane. +# +# Savane is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# Savane is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. from django.test import TestCase from django.core.urlresolvers import reverse @@ -11,6 +22,8 @@ class SimpleTest(TestCase): fixtures = [ 'tracker.yaml', + 'fieldusage.yaml', + 'fieldchoice.yaml', 'demo/item.yaml', ] @@ -20,4 +33,3 @@ """ response = self.client.get(reverse('savane:tracker:item_detail', args=('bugs', 1))) self.assertEqual(response.status_code, 200) - print response.content