Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

test_compatibility: Mock desktop minimum versions.

Tim Abbott6e9683fe6fd7
diff --git a/zerver/tests/test_compatibility.py b/zerver/tests/test_compatibility.py
index 2e138b953ce..abe6a9ec28d 100644
--- a/zerver/tests/test_compatibility.py
+++ b/zerver/tests/test_compatibility.py
@@ -109,6 +109,8 @@ class CompatibilityTest(ZulipTestCase):
else:
assert False # nocoverage
+ @mock.patch("zerver.views.compatibility.DESKTOP_MINIMUM_VERSION", "5.0.0")
+ @mock.patch("zerver.views.compatibility.DESKTOP_WARNING_VERSION", "5.2.0")
def test_insecure_desktop_app(self) -> None:
self.assertEqual(is_outdated_desktop_app("ZulipDesktop/0.5.2 (Mac)"), (True, True, True))
self.assertEqual(