cover another missing setting

This commit is contained in:
Matthias 2022-01-09 23:01:38 +01:00
parent afada6b759
commit bf7af8f72a
No known key found for this signature in database
GPG Key ID: F50EF5741D33E076

View File

@ -176,7 +176,13 @@ class APICallMixinTest(BaseMixinDefinition, TestCase):
pass
self.mixin_wrong = WrongCLS()
class WrongCLS2(APICallMixin, IntegrationPluginBase):
API_URL_SETTING = 'test'
self.mixin_wrong2 = WrongCLS2()
def test_function(self):
# check init
self.assertTrue(self.mixin.has_api_call())
# api_url
self.assertEqual('https://reqres.in', self.mixin.api_url)
@ -204,6 +210,10 @@ class APICallMixinTest(BaseMixinDefinition, TestCase):
with self.assertRaises(ValueError):
self.mixin_wrong.has_api_call()
# cover wrong token setting
with self.assertRaises(ValueError):
self.mixin_wrong.has_api_call()
class IntegrationPluginBaseTests(TestCase):
""" Tests for IntegrationPluginBase """