From 241101cee67a43e00083e2b18319b019ddcaf3d2 Mon Sep 17 00:00:00 2001 From: Matthias Date: Sun, 13 Feb 2022 23:48:48 +0100 Subject: [PATCH] remove coverage that is not reachable --- InvenTree/plugin/integration.py | 8 ++++---- InvenTree/plugin/templatetags/plugin_extras.py | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/InvenTree/plugin/integration.py b/InvenTree/plugin/integration.py index ccf1f6d2eb..74d8e930cb 100644 --- a/InvenTree/plugin/integration.py +++ b/InvenTree/plugin/integration.py @@ -135,7 +135,7 @@ class IntegrationPluginBase(MixinBase, plugin_base.InvenTreePluginBase): if not author: author = self.package.get('author') if not author: - author = _('No author found') + author = _('No author found') # pragma: no cover return author @property @@ -149,7 +149,7 @@ class IntegrationPluginBase(MixinBase, plugin_base.InvenTreePluginBase): else: pub_date = datetime.fromisoformat(str(pub_date)) if not pub_date: - pub_date = _('No date found') + pub_date = _('No date found') # pragma: no cover return pub_date @property @@ -241,11 +241,11 @@ class IntegrationPluginBase(MixinBase, plugin_base.InvenTreePluginBase): # process sign state sign_state = getattr(GitStatus, str(package.get('verified')), GitStatus.N) if sign_state.status == 0: - self.sign_color = 'success' + self.sign_color = 'success' # pragma: no cover elif sign_state.status == 1: self.sign_color = 'warning' else: - self.sign_color = 'danger' + self.sign_color = 'danger' # pragma: no cover # set variables self.package = package diff --git a/InvenTree/plugin/templatetags/plugin_extras.py b/InvenTree/plugin/templatetags/plugin_extras.py index f9557c84ff..9e83cf96aa 100644 --- a/InvenTree/plugin/templatetags/plugin_extras.py +++ b/InvenTree/plugin/templatetags/plugin_extras.py @@ -52,7 +52,7 @@ def navigation_enabled(*args, **kwargs): """ if djangosettings.PLUGIN_TESTING: return True - return InvenTreeSetting.get_setting('ENABLE_PLUGINS_NAVIGATION') + return InvenTreeSetting.get_setting('ENABLE_PLUGINS_NAVIGATION') # pragma: no cover @register.simple_tag()