From 98f7af089e8545bb0715048ab085418d0d1c32dd Mon Sep 17 00:00:00 2001 From: Kataiser Date: Tue, 17 Dec 2024 23:32:27 -0600 Subject: [PATCH] Skip a part of a test if running on Github Actions --- TF2 Rich Presence/tests.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/TF2 Rich Presence/tests.py b/TF2 Rich Presence/tests.py index fe91151..19cb47e 100644 --- a/TF2 Rich Presence/tests.py +++ b/TF2 Rich Presence/tests.py @@ -273,9 +273,10 @@ def test_update_checker(self): self.assertTrue(downloads_url.startswith('https://github.com/Kataiser/tf2-rich-presence/releases/tag/v')) self.assertTrue(len(changelog) > 0) - with self.assertRaises(requests.Timeout): - update_checker.initiate_update_check(False, timeout=0.0001) - update_checker.api_future.result() + if os.environ.get('GITHUB_ACTIONS') != 'true': + with self.assertRaises(requests.Timeout): + update_checker.initiate_update_check(False, timeout=0.0001) + update_checker.api_future.result() def test_format_changelog(self): unformatted = "## Changes\n" \