Update json_to_md.py
Run Pytest with Allure and Coverage Reports / tests (push) Successful in 42s

This commit is contained in:
2025-07-14 16:57:47 +02:00
parent 5abfcfc8fb
commit d6dd3cba90
+2 -5
View File
@@ -253,18 +253,15 @@ def check_keyboard_interrupt_and_prepend_warning(log_path, md_path):
break
if interrupt_file_line:
# Lire le contenu existant du report
with open(md_path, "r") as f:
original = f.read()
# Fabriquer le header davertissement
warning = (
"⚠️ **Tests interrupted by `KeyboardInterrupt`**\n\n"
"⚠️⚠️⚠️ **TESTS INTERRUPTED BY `KeyboardInterrupt`** ⚠️⚠️⚠️ \n\n"
f"> Source: `{interrupt_file_line}`\n\n"
"---\n\n"
)
# Réécrire le fichier avec lalerte en haut
with open(md_path, "w") as f:
f.write(warning + original)
@@ -294,4 +291,4 @@ def main():
if __name__ == "__main__":
main()
main()