mirror of
https://github.com/inventree/InvenTree.git
synced 2026-11-18 22:17:51 +00:00
Fit for unit test (#3426)
* Fit for unit test
- Write known value to setting before perfoming read test
(cherry picked from commit 7042d8b9badb7bf50f6f6566c3d4171d68d43f0c)
* Allow longer timeout for image download tests
(cherry picked from commit e1ce13043f)
This commit is contained in:
1 parent
2b1658e513
commit
4d5e267753
2 files changed
+7
-5
No files matched your search
@@ -534,8 +534,10 @@ class NotificationUserSettingsApiTest(InvenTreeAPITestCase):
|
||||
|
||||
def test_setting(self):
|
||||
"""Test the string name for NotificationUserSetting."""
|
||||
|
||||
NotificationUserSetting.set_setting('NOTIFICATION_METHOD_MAIL', True, change_user=self.user, user=self.user)
|
||||
test_setting = NotificationUserSetting.get_setting_object('NOTIFICATION_METHOD_MAIL', user=self.user)
|
||||
self.assertEqual(str(test_setting), 'NOTIFICATION_METHOD_MAIL (for testuser): ')
|
||||
self.assertEqual(str(test_setting), 'NOTIFICATION_METHOD_MAIL (for testuser): True')
|
||||
|
||||
|
||||
class PluginSettingsApiTest(InvenTreeAPITestCase):
|
||||
|
||||
Reference in new issue
Block a user