aboutsummaryrefslogtreecommitdiffstats
path: root/testing
diff options
context:
space:
mode:
authorChristian Tismer <tismer@stackless.com>2021-07-28 13:35:09 +0200
committerChristian Tismer <tismer@stackless.com>2021-07-28 14:16:44 +0200
commitecc588bfbc15c1c344093601374e16c4e64dc075 (patch)
treef877b526edc9e742c56a7c337d68e0105bf9c32b /testing
parent01ea79fbb6a57f22a587d34252f0a256abfdf01f (diff)
testing: use f-strings, fix
f-string usage was wrong in command.py with triple-quotes. The effect was quite visible when inspection build logs. Also note: f-string expressions cannot contain back-slashes. Amends 8c1b6d88c19633a7373c052a2af3f584ad2114f7. Change-Id: I9f02c19d6993fa5b47bb07f361297fbe8c105749 Pick-to: 6.1 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'testing')
-rw-r--r--testing/command.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/testing/command.py b/testing/command.py
index 307a59761..2bed65070 100644
--- a/testing/command.py
+++ b/testing/command.py
@@ -261,14 +261,15 @@ def main():
key, value = things
os.environ[key] = value
+ version = sys.version.replace("\n", " ")
print(
dedent(
- """\
+ f"""\
System:
- Platform={sys.__dict__["platform"]}
- Executable={sys.__dict__["executable"]}
- Version={sys.version.replace("\n", " ")}
- API version={sys.__dict__["api_version"]}
+ Platform={sys.platform}
+ Executable={sys.executable}
+ Version={version}
+ API version={sys.api_version}
Environment:"""
)