Skip to content

Commit

Permalink
Fix isort error, blow off mypy errors
Browse files Browse the repository at this point in the history
  • Loading branch information
mlabonte-rh committed Aug 16, 2024
1 parent 386ce4b commit c0ca638
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions tests/interop/create_ci_badge.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import json
import os
import subprocess
from junitparser import JUnitXml
from datetime import datetime

from junitparser import JUnitXml

oc = os.environ["HOME"] + "/oc_client/oc"

ci_badge = {
Expand Down Expand Up @@ -54,8 +55,8 @@ def get_openshift_version():

for file in os.listdir(results_dir):
if file.startswith("test_") and file.endswith(".xml"):
with open(os.path.join(results_dir, file), "r") as result_file:
xml = JUnitXml.fromfile(result_file)
with open(os.path.join(results_dir, file), "r") as result_file: # type: ignore
xml = JUnitXml.fromfile(result_file) # type: ignore
for suite in xml:
for case in suite:
if case.result:
Expand All @@ -70,14 +71,14 @@ def get_openshift_version():
ci_badge["message"] = ci_badge["patternBranch"]

ci_badge_json_basename = (
os.environ.get("PATTERN_SHORTNAME")
os.environ.get("PATTERN_SHORTNAME") # type: ignore
+ "-"
+ os.environ.get("INFRA_PROVIDER")
+ "-"
+ versions[1]
+ "-stable-badge.json"
)
ci_badge_json_filename = os.path.join(results_dir, ci_badge_json_basename)
ci_badge_json_filename = os.path.join(results_dir, ci_badge_json_basename) # type: ignore
print(f"Creating CI badge file at: {ci_badge_json_filename}")

with open(ci_badge_json_filename, "w") as ci_badge_file:
Expand Down

0 comments on commit c0ca638

Please sign in to comment.