Merge lp:~adeuring/launchpad/bug-588276 into lp:launchpad

Proposed by Abel Deuring
Status: Merged
Approved by: Graham Binns
Approved revision: no longer in the source branch.
Merged at revision: 11018
Proposed branch: lp:~adeuring/launchpad/bug-588276
Merge into: lp:launchpad
Diff against target: 524 lines (+343/-11)
9 files modified
lib/lp/bugs/browser/bugtarget.py (+45/-1)
lib/lp/bugs/browser/tests/test_bugtarget_configure.py (+5/-1)
lib/lp/bugs/browser/tests/test_bugtarget_filebug.py (+264/-0)
lib/lp/bugs/stories/guided-filebug/xx-bug-reporting-guidelines.txt (+18/-2)
lib/lp/registry/browser/distribution.py (+2/-1)
lib/lp/registry/browser/distributionsourcepackage.py (+1/-0)
lib/lp/registry/browser/project.py (+3/-2)
lib/lp/registry/browser/tests/distribution-views.txt (+4/-3)
lib/lp/registry/browser/tests/distributionsourcepackage-views.txt (+1/-1)
To merge this branch: bzr merge lp:~adeuring/launchpad/bug-588276
Reviewer Review Type Date Requested Status
Graham Binns (community) code Approve
Review via email: mp+27606@code.launchpad.net

Description of the change

This branch fixes bug 588276: "Enable use of bug_reported_acknowledgement in web UI"

It adds the field bug_reported_acknowledgement to edit forms for IDistribution, IDistributionSourcePackage, IProduct, IProjectGroup; FileBugViewBase.submit_bug_action() now tries to retrieve the bug filing acknowledgement message from the bug target and its parents. This is done in the new method getAcknowledgementMessage().

The property bug_reported_acknowledgement is defined for all bug targets, but only the four bug target types IDistribution, IDistributionSourcePackage, IProduct, IProjectGroup have database columns for it; other bug targets (IProductSeries, IDistroSeries, ISourcePackage) inherit it from their parents.

This acquisition logic is fine, but it ignores the case that a customized message is defined for a project group but not for a project within the project group, or for a distribution but not for DistributionSourcePackage. We should show in this case not the standard messae, but the message defined for the project group or the distribution, respectively.

Hence I duplicated/generalized the "acquisition logic" in the browser class method getAcknowledgementmessage() so that it works for DSP -> distribtuion and product -> project group too.

tests:

bin/test -t test_bugtarget_filebug (for getAcknowledgementmessage())
bin/test -t xx-bug-reporting-guidelines.txt (changes edit forms; shows that the notification shown in the web UI when a bug has been filed is customnizable).

no lint

To post a comment you must log in.
Revision history for this message
Graham Binns (gmb) wrote :

> + "bug_reported_acknowledgement",
> ]
> custom_widget('bugtracker', ProductBugTrackerWidget)
>
> @@ -443,7 +446,7 @@
> else:
> private = False
>
> - notifications = ["Thank you for your bug report."]
> + notifications = [self.getAcknowledgementMessage(self.context)]
> params = CreateBugParams(
> title=title, comment=comment, owner=self.user,
> security_related=security_related, private=private,
> @@ -775,6 +778,47 @@
> })
> return guidelines
>
> + default_bug_reported_acknowledgement = "Thank you for your bug report."
> +
> + def getAcknowledgementMessage(self, context):
> + """An acknowlegement message displayed to the user."""
> + # If a given context has not a custom message, we go up in the

Minor grammatical nit pick: "does not have a" reads better than "has not a".

review: Approve (code)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'lib/lp/bugs/browser/bugtarget.py'
--- lib/lp/bugs/browser/bugtarget.py 2010-06-08 10:36:00 +0000
+++ lib/lp/bugs/browser/bugtarget.py 2010-06-16 08:24:32 +0000
@@ -120,6 +120,8 @@
120 remote_product = copy_field(IProduct['remote_product'])120 remote_product = copy_field(IProduct['remote_product'])
121 bug_reporting_guidelines = copy_field(121 bug_reporting_guidelines = copy_field(
122 IBugTarget['bug_reporting_guidelines'])122 IBugTarget['bug_reporting_guidelines'])
123 bug_reported_acknowledgement = copy_field(
124 IBugTarget['bug_reported_acknowledgement'])
123125
124126
125def product_to_productbugconfiguration(product):127def product_to_productbugconfiguration(product):
@@ -141,6 +143,7 @@
141 "enable_bug_expiration",143 "enable_bug_expiration",
142 "remote_product",144 "remote_product",
143 "bug_reporting_guidelines",145 "bug_reporting_guidelines",
146 "bug_reported_acknowledgement",
144 ]147 ]
145 custom_widget('bugtracker', ProductBugTrackerWidget)148 custom_widget('bugtracker', ProductBugTrackerWidget)
146149
@@ -443,7 +446,7 @@
443 else:446 else:
444 private = False447 private = False
445448
446 notifications = ["Thank you for your bug report."]449 notifications = [self.getAcknowledgementMessage(self.context)]
447 params = CreateBugParams(450 params = CreateBugParams(
448 title=title, comment=comment, owner=self.user,451 title=title, comment=comment, owner=self.user,
449 security_related=security_related, private=private,452 security_related=security_related, private=private,
@@ -775,6 +778,47 @@
775 })778 })
776 return guidelines779 return guidelines
777780
781 default_bug_reported_acknowledgement = "Thank you for your bug report."
782
783 def getAcknowledgementMessage(self, context):
784 """An acknowlegement message displayed to the user."""
785 # If a given context doesnot have a custom message, we go up in the
786 # "object hierachy" until we find one. If no cusotmized messages
787 # exist for any conext, a default message is returned.
788 #
789 # bug_reported_acknowledgement is defined as a "real" property
790 # for IDistribution, IDistributionSourcePackage, IProduct and
791 # IProjectGroup. Other IBugTarget implementations inherit this
792 # property from their parents. For these classes, we can directly
793 # try to find a custom message farther up in the hierarchy.
794 message = context.bug_reported_acknowledgement
795 if message is not None and len(message.strip()) > 0:
796 return message
797 next_context = None
798 if IProductSeries.providedBy(context):
799 # we don't need to look at
800 # context.product.bug_reported_acknowledgement because a
801 # product series inherits this property from the product.
802 next_context = context.product.project
803 elif IProduct.providedBy(context):
804 next_context = context.project
805 elif IDistributionSourcePackage.providedBy(context):
806 next_context = context.distribution
807 # IDistroseries and ISourcePackage inherit
808 # bug_reported_acknowledgement from their IDistribution, so we
809 # don't need to look up this property in IDistribution.
810 # IDistribution and IProjectGroup don't have any parents.
811 elif (IDistribution.providedBy(context) or
812 IProjectGroup.providedBy(context) or
813 IDistroSeries.providedBy(context) or
814 ISourcePackage.providedBy(context)):
815 pass
816 else:
817 raise TypeError("Unexpected bug target: %r" % context)
818 if next_context is not None:
819 return self.getAcknowledgementMessage(next_context)
820 return self.default_bug_reported_acknowledgement
821
778 @cachedproperty822 @cachedproperty
779 def extra_data_processing_job(self):823 def extra_data_processing_job(self):
780 """Return the ProcessApportBlobJob for a given BLOB token."""824 """Return the ProcessApportBlobJob for a given BLOB token."""
781825
=== modified file 'lib/lp/bugs/browser/tests/test_bugtarget_configure.py'
--- lib/lp/bugs/browser/tests/test_bugtarget_configure.py 2010-05-26 18:52:31 +0000
+++ lib/lp/bugs/browser/tests/test_bugtarget_configure.py 2010-06-16 08:24:32 +0000
@@ -31,6 +31,7 @@
31 'field.enable_bug_expiration': 'on',31 'field.enable_bug_expiration': 'on',
32 'field.remote_product': 'sf-boing',32 'field.remote_product': 'sf-boing',
33 'field.bug_reporting_guidelines': 'guidelines',33 'field.bug_reporting_guidelines': 'guidelines',
34 'field.bug_reported_acknowledgement': 'acknowledgement message',
34 'field.actions.change': 'Change',35 'field.actions.change': 'Change',
35 }36 }
3637
@@ -42,7 +43,7 @@
42 fields = [43 fields = [
43 'bug_supervisor', 'security_contact', 'bugtracker',44 'bug_supervisor', 'security_contact', 'bugtracker',
44 'enable_bug_expiration', 'remote_product',45 'enable_bug_expiration', 'remote_product',
45 'bug_reporting_guidelines']46 'bug_reporting_guidelines', 'bug_reported_acknowledgement']
46 self.assertEqual(fields, view.field_names)47 self.assertEqual(fields, view.field_names)
47 self.assertEqual('http://launchpad.dev/boing', view.next_url)48 self.assertEqual('http://launchpad.dev/boing', view.next_url)
48 self.assertEqual('http://launchpad.dev/boing', view.cancel_url)49 self.assertEqual('http://launchpad.dev/boing', view.cancel_url)
@@ -61,6 +62,9 @@
61 self.assertTrue(self.product.enable_bug_expiration)62 self.assertTrue(self.product.enable_bug_expiration)
62 self.assertEqual('sf-boing', self.product.remote_product)63 self.assertEqual('sf-boing', self.product.remote_product)
63 self.assertEqual('guidelines', self.product.bug_reporting_guidelines)64 self.assertEqual('guidelines', self.product.bug_reporting_guidelines)
65 self.assertEqual(
66 'acknowledgement message',
67 self.product.bug_reported_acknowledgement)
6468
65 def test_bug_supervisor_invalid(self):69 def test_bug_supervisor_invalid(self):
66 # Verify that invalid bug_supervisor states are reported.70 # Verify that invalid bug_supervisor states are reported.
6771
=== added file 'lib/lp/bugs/browser/tests/test_bugtarget_filebug.py'
--- lib/lp/bugs/browser/tests/test_bugtarget_filebug.py 1970-01-01 00:00:00 +0000
+++ lib/lp/bugs/browser/tests/test_bugtarget_filebug.py 2010-06-16 08:24:32 +0000
@@ -0,0 +1,264 @@
1# Copyright 2010 Canonical Ltd. This software is licensed under the
2# GNU Affero General Public License version 3 (see the file LICENSE).
3
4__metaclass__ = type
5
6
7import unittest
8
9from canonical.launchpad.ftests import login
10from canonical.launchpad.webapp.servers import LaunchpadTestRequest
11from canonical.testing import LaunchpadFunctionalLayer
12
13from lp.bugs.browser.bugtarget import FileBugInlineFormView
14from lp.testing import login_person, TestCaseWithFactory
15from lp.testing.views import create_initialized_view
16
17class TestBugTargetFileBugConfirmationMessage(TestCaseWithFactory):
18
19 layer = LaunchpadFunctionalLayer
20
21 def setUp(self):
22 super(TestBugTargetFileBugConfirmationMessage, self).setUp()
23 login('foo.bar@canonical.com')
24 self.product = self.factory.makeProduct()
25
26 def test_getAcknowledgementMessage_product(self):
27 # If there is not customized confirmation message, a default
28 # message is displayed.
29 product = self.factory.makeProduct()
30 view = FileBugInlineFormView(product, LaunchpadTestRequest())
31 self.assertEqual(
32 u"Thank you for your bug report.",
33 view.getAcknowledgementMessage(product))
34
35 # If a product contains a customized bug filing confirmation
36 # message, it is retrieved by
37 # FilebugViewBase.bug_reported_acknowledgement
38 product.bug_reported_acknowledgement = (
39 u"We really appreciate your bug report")
40 view = FileBugInlineFormView(product, LaunchpadTestRequest())
41 self.assertEqual(
42 u"We really appreciate your bug report",
43 view.getAcknowledgementMessage(product))
44
45 # If the custom message is set to a string containing only white,
46 # space, the default message is used again.
47 product.bug_reported_acknowledgement = ' \t'
48 view = FileBugInlineFormView(product, LaunchpadTestRequest())
49 self.assertEqual(
50 u"Thank you for your bug report.",
51 view.getAcknowledgementMessage(product))
52
53 def test_getAcknowledgementMessage_product_in_project_group(self):
54 # If a product is part of a project group and if the project
55 # group has a customized bug filing confirmation message,
56 # this message is displayed.
57 project_group = self.factory.makeProject()
58 product = self.factory.makeProduct(project=project_group)
59
60 # Without any customized bug filing confirmation message, the
61 # default message is used.
62 view = FileBugInlineFormView(product, LaunchpadTestRequest())
63 self.assertEqual(
64 u"Thank you for your bug report.",
65 view.getAcknowledgementMessage(product))
66
67 # If the project group has a customized message, it is used.
68 project_group.bug_reported_acknowledgement = (
69 "Thanks for filing a bug for one of our many products.")
70 view = FileBugInlineFormView(product, LaunchpadTestRequest())
71 self.assertEqual(
72 u"Thanks for filing a bug for one of our many products.",
73 view.getAcknowledgementMessage(product))
74
75 # But if the product itself has a customized message too, this
76 # message is used instead of the project group's message.
77 product.bug_reported_acknowledgement = (
78 u"Thanks for filing a bug for this very special product.")
79 view = FileBugInlineFormView(product, LaunchpadTestRequest())
80 self.assertEqual(
81 u"Thanks for filing a bug for this very special product.",
82 view.getAcknowledgementMessage(product))
83
84 def test_getAcknowledgementMessage_product_series(self):
85 # If there is not customized confirmation message, a default
86 # message is displayed.
87 product_series = self.factory.makeProductSeries()
88 view = FileBugInlineFormView(product_series, LaunchpadTestRequest())
89 self.assertEqual(
90 u"Thank you for your bug report.",
91 view.getAcknowledgementMessage(product_series))
92
93 # If a product contains a customized bug filing confirmation
94 # message, it is retrieved for a product series context by
95 # FilebugViewBase.bug_reported_acknowledgement
96 product_series.product.bug_reported_acknowledgement = (
97 u"We really appreciate your bug report")
98 view = FileBugInlineFormView(product_series, LaunchpadTestRequest())
99 self.assertEqual(
100 u"We really appreciate your bug report",
101 view.getAcknowledgementMessage(product_series))
102
103 def test_getAcknowledgementMessage_product_series_in_project_group(self):
104 # If a product_series is part of a project group and if the project
105 # group has a customized bug filing confirmation message,
106 # this message is displayed.
107 project_group = self.factory.makeProject()
108 product = self.factory.makeProduct(project=project_group)
109 product_series = self.factory.makeProductSeries(product=product)
110
111 # Without any customized bug filing confirmation message, the
112 # default message is used.
113 view = FileBugInlineFormView(product_series, LaunchpadTestRequest())
114 self.assertEqual(
115 u"Thank you for your bug report.",
116 view.getAcknowledgementMessage(product_series))
117
118 # If the project group has a customized message, it is used.
119 project_group.bug_reported_acknowledgement = (
120 u"Thanks for filing a bug for one of our many product_seriess.")
121 view = FileBugInlineFormView(product_series, LaunchpadTestRequest())
122 self.assertEqual(
123 u"Thanks for filing a bug for one of our many product_seriess.",
124 view.getAcknowledgementMessage(product_series))
125
126 # But if the product has a customized message too, this
127 # message is used instead of the project group's message.
128 product.bug_reported_acknowledgement = (
129 u"Thanks for filing a bug for this very special product.")
130 view = FileBugInlineFormView(product_series, LaunchpadTestRequest())
131 self.assertEqual(
132 u"Thanks for filing a bug for this very special product.",
133 view.getAcknowledgementMessage(product_series))
134
135 def test_getAcknowledgementMessage_distribution(self):
136 # If there is not customized confirmation message, a default
137 # message is displayed.
138 distribution = self.factory.makeDistribution()
139 view = FileBugInlineFormView(distribution, LaunchpadTestRequest())
140 self.assertEqual(
141 u"Thank you for your bug report.",
142 view.getAcknowledgementMessage(distribution))
143
144 # If a distribution contains a customized bug filing confirmation
145 # message, it is retrieved by
146 # FilebugViewBase.bug_reported_acknowledgement
147 distribution.bug_reported_acknowledgement = (
148 u"We really appreciate your bug report")
149 view = FileBugInlineFormView(distribution, LaunchpadTestRequest())
150 self.assertEqual(
151 u"We really appreciate your bug report",
152 view.getAcknowledgementMessage(distribution))
153
154 def test_getAcknowledgementMessage_distroseries(self):
155 # If there is not customized confirmation message, a default
156 # message is displayed.
157 distroseries = self.factory.makeDistroSeries()
158 view = FileBugInlineFormView(distroseries, LaunchpadTestRequest())
159 self.assertEqual(
160 u"Thank you for your bug report.",
161 view.getAcknowledgementMessage(distroseries))
162
163 # DistroSeries objects do not have their own, independent
164 # property bug_reported_acknowledgement; instead, it is
165 # acquired from the parent distribution.
166 distroseries.distribution.bug_reported_acknowledgement = (
167 u"We really appreciate your bug report")
168 view = FileBugInlineFormView(distroseries, LaunchpadTestRequest())
169 self.assertEqual(
170 u"We really appreciate your bug report",
171 view.getAcknowledgementMessage(distroseries))
172
173 def test_getAcknowledgementMessage_sourcepackage(self):
174 # If there is not customized confirmation message, a default
175 # message is displayed.
176 sourcepackage = self.factory.makeSourcePackage()
177 view = FileBugInlineFormView(sourcepackage, LaunchpadTestRequest())
178 self.assertEqual(
179 u"Thank you for your bug report.",
180 view.getAcknowledgementMessage(sourcepackage))
181
182 # SourcePackage objects do not have their own, independent
183 # property bug_reported_acknowledgement; instead, it is
184 # acquired from the parent distribution.
185 sourcepackage.distribution.bug_reported_acknowledgement = (
186 u"We really appreciate your bug report")
187 view = FileBugInlineFormView(sourcepackage, LaunchpadTestRequest())
188 self.assertEqual(
189 u"We really appreciate your bug report",
190 view.getAcknowledgementMessage(sourcepackage))
191
192 def test_getAcknowledgementMessage_distributionsourcepackage(self):
193 # If there is not customized confirmation message, a default
194 # message is displayed.
195 dsp = self.factory.makeDistributionSourcePackage()
196 view = FileBugInlineFormView(dsp, LaunchpadTestRequest())
197 self.assertEqual(
198 u"Thank you for your bug report.",
199 view.getAcknowledgementMessage(dsp))
200
201 # If a custom message is defined for a DSP, it is used instead of
202 # the default message.
203 dsp.bug_reported_acknowledgement = (
204 u"We really appreciate your bug report")
205 view = FileBugInlineFormView(dsp, LaunchpadTestRequest())
206 self.assertEqual(
207 u"We really appreciate your bug report",
208 view.getAcknowledgementMessage(dsp))
209
210 def test_getAcknowledgementMessage_dsp_custom_distro_message(self):
211 # If a distribution has a customized conformatom message, it
212 # is used for bugs filed on DsitributionSourcePackages.
213 dsp = self.factory.makeDistributionSourcePackage()
214 dsp.distribution.bug_reported_acknowledgement = (
215 u"Thank you for filing a bug in our distribution")
216 view = FileBugInlineFormView(dsp, LaunchpadTestRequest())
217 self.assertEqual(
218 u"Thank you for filing a bug in our distribution",
219 view.getAcknowledgementMessage(dsp))
220
221 # Bug if a custom message is defined for a DSP, it is used instead of
222 # the message for the distribution.
223 dsp.bug_reported_acknowledgement = (
224 u"Thank you for filing a bug for this DSP")
225 view = FileBugInlineFormView(dsp, LaunchpadTestRequest())
226 self.assertEqual(
227 u"Thank you for filing a bug for this DSP",
228 view.getAcknowledgementMessage(dsp))
229
230 def test_bug_filed_acknowlegdgement_notification(self):
231 # When a user files a bug, an acknowledgement notification is added
232 # to the response.
233 product = self.factory.makeProduct()
234 login_person(product.owner)
235 view = FileBugInlineFormView(product, LaunchpadTestRequest())
236 form_data = {
237 'title': 'A bug title',
238 'comment': 'whatever',
239 }
240 view = create_initialized_view(product, name='+filebug')
241 view.submit_bug_action.success(form_data)
242 self.assertEqual(
243 ["Thank you for your bug report."],
244 [notification.message
245 for notification in view.request.response.notifications])
246
247 # This message can be customized.
248 product.bug_reported_acknowledgement = (
249 u"We really appreciate your bug report")
250 view = create_initialized_view(product, name='+filebug')
251 view.submit_bug_action.success(form_data)
252 self.assertEqual(
253 [u"We really appreciate your bug report"],
254 [notification.message
255 for notification in view.request.response.notifications])
256
257def test_suite():
258 suite = unittest.TestSuite()
259 suite.addTest(unittest.makeSuite(TestBugTargetFileBugConfirmationMessage))
260 return suite
261
262
263if __name__ == '__main__':
264 unittest.TextTestRunner().run(test_suite())
0265
=== modified file 'lib/lp/bugs/stories/guided-filebug/xx-bug-reporting-guidelines.txt'
--- lib/lp/bugs/stories/guided-filebug/xx-bug-reporting-guidelines.txt 2010-03-16 22:07:45 +0000
+++ lib/lp/bugs/stories/guided-filebug/xx-bug-reporting-guidelines.txt 2010-06-16 08:24:32 +0000
@@ -1,7 +1,9 @@
1= Bug Reporting Guidelines =1= Bug Reporting Guidelines and acknowledgement messages =
22
3Some helpful explanatory text - guidelines - can be set for3Some helpful explanatory text - guidelines - can be set for
4distributions, product groups, products, and source packages.4distributions, product groups, products, and source packages, as wel
5as an acknowledgement message that is displayed when a bug has been
6filed.
57
6 >>> contexts = [8 >>> contexts = [
7 ... ('Ubuntu', 'ubuntu', '+edit'),9 ... ('Ubuntu', 'ubuntu', '+edit'),
@@ -16,6 +18,9 @@
16 ... admin_browser.getControl(18 ... admin_browser.getControl(
17 ... name='field.bug_reporting_guidelines').value = (19 ... name='field.bug_reporting_guidelines').value = (
18 ... "The version of %s you're using." % (context_name,))20 ... "The version of %s you're using." % (context_name,))
21 ... admin_browser.getControl(
22 ... name='field.bug_reported_acknowledgement').value = (
23 ... "Thank you for filing a bug for %s" % context_name)
19 ... if context_path == 'ubuntu':24 ... if context_path == 'ubuntu':
20 ... admin_browser.getControl('Change', index=3).click()25 ... admin_browser.getControl('Change', index=3).click()
21 ... else:26 ... else:
@@ -30,6 +35,9 @@
30 ... print ' <%s>' % user_browser.url35 ... print ' <%s>' % user_browser.url
31 ... print extract_text(find_tag_by_id(36 ... print extract_text(find_tag_by_id(
32 ... user_browser.contents, 'bug-reporting-guidelines'))37 ... user_browser.contents, 'bug-reporting-guidelines'))
38 >>> def print_acknowledgement_message(browser):
39 ... print extract_text(find_tags_by_class(
40 ... user_browser.contents, 'informational message')[0])
3341
34 >>> for context_name, context_path, view in contexts:42 >>> for context_name, context_path, view in contexts:
35 ... filebug_url = (43 ... filebug_url = (
@@ -49,22 +57,29 @@
49 ... user_browser.open(filebug_url)57 ... user_browser.open(filebug_url)
50 ... user_browser.getControl('Summary').value = "It doesn't work"58 ... user_browser.getControl('Summary').value = "It doesn't work"
51 ... user_browser.getControl('Continue').click()59 ... user_browser.getControl('Continue').click()
60 ... user_browser.getControl('Further information').value = (
61 ... 'please help!')
52 ... print_guidelines(context_name, user_browser)62 ... print_guidelines(context_name, user_browser)
63 ... user_browser.getControl('Submit Bug Report').click()
64 ... print_acknowledgement_message(user_browser)
53 *65 *
54 Ubuntu66 Ubuntu
55 <http://launchpad.dev/ubuntu/+filebug>67 <http://launchpad.dev/ubuntu/+filebug>
56 Ubuntu guidelines:68 Ubuntu guidelines:
57 The version of Ubuntu you're using.69 The version of Ubuntu you're using.
70 Thank you for filing a bug for Ubuntu
58 *71 *
59 Mozilla72 Mozilla
60 <http://launchpad.dev/mozilla/+filebug>73 <http://launchpad.dev/mozilla/+filebug>
61 The Mozilla Project guidelines:74 The Mozilla Project guidelines:
62 The version of Mozilla you're using.75 The version of Mozilla you're using.
76 Thank you for filing a bug for Mozilla
63 *77 *
64 Firefox78 Firefox
65 <http://launchpad.dev/firefox/+filebug>79 <http://launchpad.dev/firefox/+filebug>
66 Mozilla Firefox guidelines:80 Mozilla Firefox guidelines:
67 The version of Firefox you're using.81 The version of Firefox you're using.
82 Thank you for filing a bug for Firefox
68 *83 *
69 alsa-utils in Ubuntu84 alsa-utils in Ubuntu
70 <http://launchpad.dev/ubuntu/+source/alsa-utils/+filebug>85 <http://launchpad.dev/ubuntu/+source/alsa-utils/+filebug>
@@ -72,6 +87,7 @@
72 The version of alsa-utils in Ubuntu you're using.87 The version of alsa-utils in Ubuntu you're using.
73 Ubuntu guidelines:88 Ubuntu guidelines:
74 The version of Ubuntu you're using.89 The version of Ubuntu you're using.
90 Thank you for filing a bug for alsa-utils in Ubuntu
7591
76Note how the alsa-utils in Ubuntu specific guidelines were displayed92Note how the alsa-utils in Ubuntu specific guidelines were displayed
77followed by the general Ubuntu guidelines.93followed by the general Ubuntu guidelines.
7894
=== modified file 'lib/lp/registry/browser/distribution.py'
--- lib/lp/registry/browser/distribution.py 2010-05-14 08:05:23 +0000
+++ lib/lp/registry/browser/distribution.py 2010-06-16 08:24:32 +0000
@@ -767,7 +767,8 @@
767767
768 schema = IDistribution768 schema = IDistribution
769 field_names = ['displayname', 'title', 'summary', 'description',769 field_names = ['displayname', 'title', 'summary', 'description',
770 'bug_reporting_guidelines', 'icon', 'logo', 'mugshot',770 'bug_reporting_guidelines', 'bug_reported_acknowledgement',
771 'icon', 'logo', 'mugshot',
771 'official_malone', 'enable_bug_expiration',772 'official_malone', 'enable_bug_expiration',
772 'official_blueprints', 'official_rosetta',773 'official_blueprints', 'official_rosetta',
773 'official_answers', 'translation_focus', ]774 'official_answers', 'translation_focus', ]
774775
=== modified file 'lib/lp/registry/browser/distributionsourcepackage.py'
--- lib/lp/registry/browser/distributionsourcepackage.py 2010-03-03 19:15:17 +0000
+++ lib/lp/registry/browser/distributionsourcepackage.py 2010-06-16 08:24:32 +0000
@@ -478,6 +478,7 @@
478 schema = IDistributionSourcePackage478 schema = IDistributionSourcePackage
479 field_names = [479 field_names = [
480 'bug_reporting_guidelines',480 'bug_reporting_guidelines',
481 'bug_reported_acknowledgement',
481 ]482 ]
482483
483 @property484 @property
484485
=== modified file 'lib/lp/registry/browser/project.py'
--- lib/lp/registry/browser/project.py 2010-05-11 17:43:20 +0000
+++ lib/lp/registry/browser/project.py 2010-06-16 08:24:32 +0000
@@ -324,8 +324,9 @@
324 schema = IProjectGroup324 schema = IProjectGroup
325 field_names = [325 field_names = [
326 'name', 'displayname', 'title', 'summary', 'description',326 'name', 'displayname', 'title', 'summary', 'description',
327 'bug_reporting_guidelines', 'homepageurl', 'bugtracker',327 'bug_reporting_guidelines', 'bug_reported_acknowledgement',
328 'sourceforgeproject', 'freshmeatproject', 'wikiurl']328 'homepageurl', 'bugtracker', 'sourceforgeproject',
329 'freshmeatproject', 'wikiurl']
329330
330331
331 @action('Change Details', name='change')332 @action('Change Details', name='change')
332333
=== modified file 'lib/lp/registry/browser/tests/distribution-views.txt'
--- lib/lp/registry/browser/tests/distribution-views.txt 2010-05-19 16:58:45 +0000
+++ lib/lp/registry/browser/tests/distribution-views.txt 2010-06-16 08:24:32 +0000
@@ -111,9 +111,10 @@
111111
112 >>> view.field_names112 >>> view.field_names
113 ['displayname', 'title', 'summary', 'description',113 ['displayname', 'title', 'summary', 'description',
114 'bug_reporting_guidelines', 'icon', 'logo', 'mugshot', 'official_malone',114 'bug_reporting_guidelines', 'bug_reported_acknowledgement', 'icon',
115 'enable_bug_expiration', 'official_blueprints', 'official_rosetta',115 'logo', 'mugshot', 'official_malone', 'enable_bug_expiration',
116 'official_answers', 'translation_focus']116 'official_blueprints', 'official_rosetta', 'official_answers',
117 'translation_focus']
117118
118 >>> del form['field.name']119 >>> del form['field.name']
119 >>> del form['field.actions.save']120 >>> del form['field.actions.save']
120121
=== modified file 'lib/lp/registry/browser/tests/distributionsourcepackage-views.txt'
--- lib/lp/registry/browser/tests/distributionsourcepackage-views.txt 2009-12-13 11:55:40 +0000
+++ lib/lp/registry/browser/tests/distributionsourcepackage-views.txt 2010-06-16 08:24:32 +0000
@@ -165,7 +165,7 @@
165The view allows the user the set the bug_reporting_guidelines field.165The view allows the user the set the bug_reporting_guidelines field.
166166
167 >>> view.field_names167 >>> view.field_names
168 ['bug_reporting_guidelines']168 ['bug_reporting_guidelines', 'bug_reported_acknowledgement']
169169
170 >>> print package.bug_reporting_guidelines170 >>> print package.bug_reporting_guidelines
171 None171 None