From 63ee840e25e4f155003dc83df95b3b6f7af14eb2 Mon Sep 17 00:00:00 2001 From: noopur Date: Fri, 8 Nov 2024 12:07:25 +0000 Subject: [PATCH] Logging fix Signed-off-by: noopur --- .github/workflows/task_runner_e2e.yml | 2 +- tests/openfl_e2e/utils/xml_helper.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/task_runner_e2e.yml b/.github/workflows/task_runner_e2e.yml index 69e5bb3dc0..ba5c5c06c7 100644 --- a/.github/workflows/task_runner_e2e.yml +++ b/.github/workflows/task_runner_e2e.yml @@ -79,7 +79,7 @@ jobs: id: run_task_runner_tests run: | pytest -v tests/openfl_e2e/test_suites/task_runner_tests.py -m ${{ env.MODEL_NAME }} -s --num_rounds $NUM_ROUNDS --num_collaborators $NUM_COLLABORATORS --model_name ${{ env.MODEL_NAME }} - echo "Task runner regression test run completed" + echo "Task runner e2e test run completed" env: NO_PROXY: localhost,127.0.0.1,aggregator diff --git a/tests/openfl_e2e/utils/xml_helper.py b/tests/openfl_e2e/utils/xml_helper.py index 56ced867db..7fa753ea65 100644 --- a/tests/openfl_e2e/utils/xml_helper.py +++ b/tests/openfl_e2e/utils/xml_helper.py @@ -5,6 +5,8 @@ from lxml import etree import os +from tests.openfl_e2e.utils.logger import logger as log + # Initialize the XML parser parser = etree.XMLParser(recover=True, encoding='utf-8') tree = ET.parse("results/results.xml", parser=parser) @@ -61,7 +63,7 @@ def get_testcase_result(): database_list.append(database_dict) status = None - print(f"Database list = {database_list}") + log.info(f"Database list = {database_list}") return database_list @@ -69,6 +71,7 @@ def get_testcase_result(): # Write the results to GitHub step summary with open(os.getenv('GITHUB_STEP_SUMMARY'), 'a') as fh: + # DO NOT change the print statements print("| Name | Time (in seconds) | Result |", file=fh) print("| ------------- | ------------- | ------------- |", file=fh) for item in result: