Commit 2e2323e0 authored by Nicolas Dandrimont's avatar Nicolas Dandrimont 🤔
Browse files

Modify the native plugin to conform to other plugins

parent e6d3d8e6
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
# This file is part of debexpo - http://debexpo.workaround.org # This file is part of debexpo - http://debexpo.workaround.org
# #
# Copyright © 2008 Jonny Lamb <jonny@debian.org> # Copyright © 2008 Jonny Lamb <jonny@debian.org>
# Copyright © 2012 Nicolas Dandrimont <Nicolas.Dandrimont@crans.org>
# #
# Permission is hereby granted, free of charge, to any person # Permission is hereby granted, free of charge, to any person
# obtaining a copy of this software and associated documentation # obtaining a copy of this software and associated documentation
...@@ -32,7 +33,10 @@ Holds the native plugin. ...@@ -32,7 +33,10 @@ Holds the native plugin.
""" """
__author__ = 'Jonny Lamb' __author__ = 'Jonny Lamb'
__copyright__ = 'Copyright © 2008 Jonny Lamb' __copyright__ = ", ".join([
'Copyright © 2008 Jonny Lamb',
'Copyright © 2012 Nicolas Dandrimont',
])
__license__ = 'MIT' __license__ = 'MIT'
import logging import logging
...@@ -57,14 +61,9 @@ class NativePlugin(BasePlugin): ...@@ -57,14 +61,9 @@ class NativePlugin(BasePlugin):
# Most uploads will not be native, and especially on mentors, a native # Most uploads will not be native, and especially on mentors, a native
# package is almost probably in error. # package is almost probably in error.
log.warning('Package is native') log.warning('Package is native')
self.failed('is-native', None, constants.PLUGIN_SEVERITY_WARNING) self.failed('Package is native', {"native": True}, constants.PLUGIN_SEVERITY_WARNING)
else: else:
log.debug('Package is not native') log.debug('Package is not native')
self.passed('is-not-native', None, constants.PLUGIN_SEVERITY_INFO) self.passed('Package is not native', {"native": False}, constants.PLUGIN_SEVERITY_INFO)
plugin = NativePlugin plugin = NativePlugin
outcomes = {
'is-native' : { 'name' : 'Package is native' },
'is-not-native' : { 'name' : 'Package is not native' },
}
<div class="qa-header">
${o.outcome}
</div>
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment