Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
mentors.debian.net
debexpo
Commits
95e8a814
Commit
95e8a814
authored
Aug 17, 2012
by
Clément Schreiner
Browse files
Small fixes (result class name, ClosedBug.__str__, severity).
parent
a6c16026
Changes
1
Hide whitespace changes
Inline
Side-by-side
debexpo/plugins/closedbugs.py
View file @
95e8a814
...
...
@@ -49,7 +49,7 @@ from debexpo.model import meta
log
=
logging
.
getLogger
(
__name__
)
@
test_result
class
ClosedbugTest
(
PluginResult
):
class
Closedbug
s
Test
(
PluginResult
):
"""
Represents the result of the 'closed bugs' test.
"""
...
...
@@ -77,10 +77,10 @@ class ClosedbugTest(PluginResult):
plural
=
's'
if
self
.
nb_closed
>
1
else
''
))
if
self
.
nb_errors
:
strings
.
append
(
'
has {} bug{plural} not closed properly
'
.
format
(
strings
.
append
(
'
claims to be closing {} bug{plural}
'
.
format
(
self
.
nb_errors
,
plural
=
's'
if
self
.
nb_closed
>
1
else
''
))
return
'Package '
+
'
and
'
.
join
(
strings
)
return
'Package '
+
'
but
'
.
join
(
strings
)
class
ClosedBug
(
PluginResult
):
"""
...
...
@@ -179,7 +179,7 @@ class ClosedBugsPlugin(QAPlugin):
bug_result
.
belongs
=
False
bug_result
.
is_error
=
True
test_result
.
nb_errors
+=
1
severity
=
max
(
severity
,
constants
.
PLUGIN_SEVERITY_ERROR
)
test_result
[
'
severity
'
]
=
max
(
severity
,
constants
.
PLUGIN_SEVERITY_ERROR
)
continue
bug_result
.
exists
=
True
...
...
@@ -212,6 +212,6 @@ class ClosedBugsPlugin(QAPlugin):
plugin
=
ClosedBugsPlugin
models
=
[
ClosedbugTest
,
Closedbug
s
Test
,
ClosedBug
,
]
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment