Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Add gtest_10x test runner #9899

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

breezewish
Copy link
Member

@breezewish breezewish commented Feb 21, 2025

What problem does this PR solve?

Issue Number: ref #6233

Problem Summary:

What is changed and how it works?

Currently unit test is slow, takes 30 minutes in CI. Slow comes from:

  1. Each test requires tear-up and tear-down, takes nearly 2s, even if the test case cost 1ms.
  2. Some tests are very slow, takes 10+ minutes to finish.

This PR introduce a new test runner called gtest_10x, 10x faster by:

  1. Batch tests, one tear-up and tear-down for multiple tests.
  2. Reject tests who takes > 1 minute to complete (rejected about 1.5% of all tests).
  3. Isolate each tests to run in a different working directory so that tests from the same test suites can be run concurrently.

Additional features:

  1. Auto rerun tests multiple times to suffer from flaky tests.

Usage:

python3 tests/gtest_10x.py cmake-build-Debug/dbms/gtests_dbms

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

None

@ti-chi-bot ti-chi-bot bot added the release-note-none Denotes a PR that doesn't merit a release note. label Feb 21, 2025
Copy link
Contributor

ti-chi-bot bot commented Feb 21, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please ask for approval from breezewish, ensuring that each of them provides their approval before proceeding. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Feb 21, 2025
Signed-off-by: Wish <[email protected]>
Copy link
Contributor

ti-chi-bot bot commented Feb 24, 2025

@breezewish: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
pull-unit-test 1286a26 link true /test pull-unit-test

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note-none Denotes a PR that doesn't merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant