mirror of
https://github.com/inventree/InvenTree.git
synced 2025-04-30 04:26:44 +00:00
add more plugin coverage
This commit is contained in:
parent
f765f0f083
commit
2335a8c316
@ -22,6 +22,7 @@ class PluginDetailAPITest(InvenTreeAPITestCase):
|
|||||||
self.MSG_NO_PKG = 'Either packagename of URL must be provided'
|
self.MSG_NO_PKG = 'Either packagename of URL must be provided'
|
||||||
|
|
||||||
self.PKG_NAME = 'minimal'
|
self.PKG_NAME = 'minimal'
|
||||||
|
self.PKG_URL = 'git+https://github.com/geoffrey-a-reed/minimal'
|
||||||
super().setUp()
|
super().setUp()
|
||||||
|
|
||||||
def test_plugin_install(self):
|
def test_plugin_install(self):
|
||||||
@ -35,7 +36,13 @@ class PluginDetailAPITest(InvenTreeAPITestCase):
|
|||||||
'confirm': True,
|
'confirm': True,
|
||||||
'packagename': self.PKG_NAME
|
'packagename': self.PKG_NAME
|
||||||
}, expected_code=201).data
|
}, expected_code=201).data
|
||||||
|
self.assertEqual(data['success'], True)
|
||||||
|
|
||||||
|
# valid - github url
|
||||||
|
data = self.post(url, {
|
||||||
|
'confirm': True,
|
||||||
|
'url': self.PKG_URL
|
||||||
|
}, expected_code=201).data
|
||||||
self.assertEqual(data['success'], True)
|
self.assertEqual(data['success'], True)
|
||||||
|
|
||||||
# invalid tries
|
# invalid tries
|
||||||
|
Loading…
x
Reference in New Issue
Block a user