From f78ff346d415ef64ba8643f2b9e6d88ef1b2ed3f Mon Sep 17 00:00:00 2001 From: "Dan Ryan (GitHub Noreply Key)" Date: Tue, 12 Nov 2024 13:42:33 -0500 Subject: [PATCH] =?UTF-8?q?=E2=99=BB=EF=B8=8F=20change=20tests=20to=20supp?= =?UTF-8?q?ort=20XDG=5FCONFIG=5FHOME=20change?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/test.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/test.py b/tests/test.py index 1a83bf2..52ee611 100644 --- a/tests/test.py +++ b/tests/test.py @@ -444,6 +444,15 @@ def test_check_without_check_file_path_with_XDG_CONFIG_HOME_set(self): msg="check_for_updates returns True or False or None when there isn't a check file path and XDG_CONFIG_HOME is set", ) + def test_check_without_check_file_path_with_XDG_CONFIG_HOME_not_set(self): + with patch.dict("os.environ", {"XDG_CONFIG_HOME": None}): + result = d3ploy.check_for_updates(None, "0.0.0") + self.assertIn( + result, + [True, False, None], + msg="check_for_updates returns True or False or None when there isn't a check file path and XDG_CONFIG_HOME is not set", + ) + class UploadFileTestCase( BaseTestCase,