diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-10-10 09:54:13 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-10-10 09:54:13 +0000 |
commit | 26cac87f1cb90abc2fac2144a39ad88b3b70031d (patch) | |
tree | f97c513314a569fb51f1c8580b012d418c05fede /tests/lib/helpers.py | |
parent | Adding upstream version 0.8.2. (diff) | |
download | eos-downloader-26cac87f1cb90abc2fac2144a39ad88b3b70031d.tar.xz eos-downloader-26cac87f1cb90abc2fac2144a39ad88b3b70031d.zip |
Adding upstream version 0.9.0.upstream/0.9.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/lib/helpers.py')
-rw-r--r-- | tests/lib/helpers.py | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/tests/lib/helpers.py b/tests/lib/helpers.py index 308f2a5..67e914b 100644 --- a/tests/lib/helpers.py +++ b/tests/lib/helpers.py @@ -5,14 +5,13 @@ # flake8: noqa: W503 # flake8: noqa: W1202 -from __future__ import (absolute_import, division, print_function) +from __future__ import absolute_import, division, print_function import os from eos_downloader.data import DATA_MAPPING - def default_filename(version: str, info): """ default_filename Helper to build default filename @@ -31,10 +30,14 @@ def default_filename(version: str, info): """ if version is None or info is None: return None - return DATA_MAPPING[info['software']]['default']['prepend'] + '-' + version + '.swi' + return DATA_MAPPING[info["software"]]["default"]["prepend"] + "-" + version + ".swi" def is_on_github_actions(): """Check if code is running on a CI runner""" - if "CI" not in os.environ or not os.environ["CI"] or "GITHUB_RUN_ID" not in os.environ: - return False
\ No newline at end of file + if ( + "CI" not in os.environ + or not os.environ["CI"] + or "GITHUB_RUN_ID" not in os.environ + ): + return False |