From dcbd9d906bd1b55251e52e66c455b32af1fa756b Mon Sep 17 00:00:00 2001 From: Matthias Mair Date: Sun, 15 May 2022 04:47:45 +0200 Subject: [PATCH] Update errors --- InvenTree/plugin/base/integration/test_mixins.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/InvenTree/plugin/base/integration/test_mixins.py b/InvenTree/plugin/base/integration/test_mixins.py index c9d32f8abb..ef3f7062e3 100644 --- a/InvenTree/plugin/base/integration/test_mixins.py +++ b/InvenTree/plugin/base/integration/test_mixins.py @@ -8,6 +8,7 @@ from django.contrib.auth import get_user_model from plugin import InvenTreePlugin from plugin.mixins import AppMixin, SettingsMixin, UrlsMixin, NavigationMixin, APICallMixin from plugin.urls import PLUGIN_BASE +from plugin.helpers import MixinNotImplementedError class BaseMixinDefinition: @@ -237,9 +238,9 @@ class APICallMixinTest(BaseMixinDefinition, TestCase): def test_function_errors(self): """Test function errors""" # wrongly defined plugins should not load - with self.assertRaises(ValueError): + with self.assertRaises(MixinNotImplementedError): self.mixin_wrong.has_api_call() # cover wrong token setting - with self.assertRaises(ValueError): + with self.assertRaises(MixinNotImplementedError): self.mixin_wrong2.has_api_call()