2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-16 12:05:53 +00:00

Update unit tests

This commit is contained in:
Oliver Walters
2024-11-18 11:37:31 +00:00
parent 0e4a95ce63
commit 144565d937

View File

@ -1184,18 +1184,8 @@ class TestSettings(InvenTreeTestCase):
"""Test if install of plugins on startup works."""
from plugin import registry
if not settings.DOCKER:
# Check an install run
response = registry.install_plugin_file()
self.assertEqual(response, 'first_run')
# Set dynamic setting to True and rerun to launch install
InvenTreeSetting.set_setting('PLUGIN_ON_STARTUP', True, self.user)
registry.reload_plugins(full_reload=True)
# Check that there was another run
response = registry.install_plugin_file()
self.assertEqual(response, True)
registry.reload_plugins(full_reload=True, collect=True)
self.assertGreater(len(settings.PLUGIN_FILE_HASH), 0)
def test_helpers_cfg_file(self):
"""Test get_config_file."""