Skip to content

Conversation

@chandrasekaranpradeep
Copy link
Contributor

@chandrasekaranpradeep chandrasekaranpradeep commented Oct 7, 2025

This pull request enhances the Update Test Durations workflow with several important improvements and configurable features for better control and reporting.

Summary of Enhancements

1. Selective Duration Overriding (New Input: override_test_durations)

  • Previously, the workflow completely overwrote the existing .test_durations file using only the tests from the latest nightly and push runs.
  • The new enhancement introduces an override_test_durations input that enables merge mode, where only the durations of existing tests are updated instead of erasing the full file.
  • This provides flexibility to selectively override existing durations when necessary.

2. Offset-Based Update Control (New Input: duration_offset)

  • Introduced an offset threshold to avoid unnecessary updates due to small fluctuations in test durations.
  • When override_test_durations is enabled, a test duration is only updated if the absolute difference between the new (nightly/push) duration and the existing duration exceeds the specified duration_offset value.
  • The default offset is set to 50 seconds, and this value can be customized through workflow inputs.

3. Detailed Test Duration Report Generation

  • The workflow now generates an Excel report (test_duration_report.xlsx) containing:
    • The old and new durations for each test, and
    • A status column indicating whether each test was newly added or updated.
  • This provides better visibility into test duration changes across runs.

4. Automatic Pull Request Merging (New Input: enable_auto_pr_merge)

  • Added the enable_auto_pr_merge input to allow automatic merging of the generated PR once it’s successfully created.
  • When enabled, the workflow will execute a squash and auto-merge of the PR.

@chandrasekaranpradeep chandrasekaranpradeep force-pushed the pchandrasekaran/update_test_duration branch from 7947864 to d4f185c Compare October 7, 2025 06:22
@codecov-commenter
Copy link

codecov-commenter commented Oct 7, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 62.65%. Comparing base (4ae5ec9) to head (d945390).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2984   +/-   ##
=======================================
  Coverage   62.65%   62.65%           
=======================================
  Files         156      156           
  Lines       13266    13266           
=======================================
  Hits         8312     8312           
  Misses       4954     4954           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@chandrasekaranpradeep chandrasekaranpradeep force-pushed the pchandrasekaran/update_test_duration branch 13 times, most recently from 3576368 to 4ca94d2 Compare October 8, 2025 09:57
@chandrasekaranpradeep chandrasekaranpradeep force-pushed the pchandrasekaran/update_test_duration branch from 4ca94d2 to d945390 Compare October 8, 2025 11:10
"""
Create a simple Excel file with headers and rows and basic styling.
"""
workbook = Workbook()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excel? Ahm, why not using python set? test_durations is quite a simple file...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dumping the test duration updates to an Excel report provides a clear, visual comparison of test duration changes. It helps us easily identify whether a test case is newly added or if its duration has been updated, along with the previous and current values side by side.

Attached the generated excel for better visualization,

test_duration_report.xlsx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants