From 23f9d868f2d7427b88c5587d45a072c8bb2fd206 Mon Sep 17 00:00:00 2001 From: Vilem Zavodny Date: Thu, 30 Jan 2025 09:20:57 +0100 Subject: [PATCH] no message --- .github/workflows/build-run-applications.yml | 7 +++++++ .../pytest_display_lvgl_benchmark.py | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-run-applications.yml b/.github/workflows/build-run-applications.yml index 4aa06bc8..32c0132a 100644 --- a/.github/workflows/build-run-applications.yml +++ b/.github/workflows/build-run-applications.yml @@ -247,3 +247,10 @@ jobs: with: comment-tag: benchmark_results file-path: ${{ env.output_file }} + - name: Commit test results + run: | + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" + git add . + git commit -m "🔄 Benchmark results" + git push origin HEAD:${{ github.head_ref }} diff --git a/examples/display_lvgl_benchmark/pytest_display_lvgl_benchmark.py b/examples/display_lvgl_benchmark/pytest_display_lvgl_benchmark.py index 5e40c6d4..ef9817d7 100644 --- a/examples/display_lvgl_benchmark/pytest_display_lvgl_benchmark.py +++ b/examples/display_lvgl_benchmark/pytest_display_lvgl_benchmark.py @@ -36,10 +36,10 @@ def write_json_file(board, data): file_path = f"{repo_root}/bsp/{board}/benchmark.json" try: os.remove(file_path) + with open(file_path, "a") as file: + file.write(data) except OSError: pass - with open(file_path, "a") as file: - file.write(data) def find_test_results(json_obj, test):