Skip to content

[CI] Update logic for which tests get run - #13457

Merged
titusfortner merged 2 commits into
trunkfrom
merge_check
Jan 18, 2024
Merged

[CI] Update logic for which tests get run#13457
titusfortner merged 2 commits into
trunkfrom
merge_check

Conversation

@titusfortner

@titusfortner titusfortner commented Jan 18, 2024

Copy link
Copy Markdown
Member

For instance I have this PR:
https://github.com/SeleniumHQ/selenium/pull/13452/commits

The GitHub Workflow evaluates as:
https://github.com/SeleniumHQ/selenium/actions/runs/7572844428/job/20623620638#step:4:7

Which you can see includes things that were added to trunk since the PR was made:
6127b5f...ac3be18

The commit getting used (github.event.pull_request.base.sha) is the merge commit. This PR gets the parent of that commit and uses that instead. If it isn't a PR it keeps current behavior.

Example of this PR in same context:
https://github.com/SeleniumHQ/selenium/actions/runs/7574277822/job/20628303353#step:7:8
which shows just the commits we want:
6127b5f...1d44724

This has the advantage of not running extra tests based on what has been added to trunk since the PR was created and/or not requiring clicking the "update branch" button. I can't think of a scenario where this isn't what we want to do, but maybe I'm missing something?

@titusfortner titusfortner added the B-build Includes scripting, bazel and CI integrations label Jan 18, 2024
@titusfortner
titusfortner requested review from diemol and p0deje January 18, 2024 18:55
@titusfortner titusfortner changed the title Merge check [CI] Update logic for which tests get run Jan 18, 2024
Comment thread .github/workflows/ci.yml

@p0deje p0deje left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think there is even simpler way to do it.

@titusfortner

Copy link
Copy Markdown
Member Author

updated. simpler.

@titusfortner
titusfortner merged commit 907f2df into trunk Jan 18, 2024
@titusfortner
titusfortner deleted the merge_check branch January 18, 2024 19:52
@titusfortner

Copy link
Copy Markdown
Member Author

Ugh, the new code is doing:
63804e9..82bf8fb
Which is including the code changes from 63804e9 in the PR for some reason, which isn't what we want 😦

@p0deje any ideas? I'll try again later if I find time.

@p0deje

p0deje commented Jan 20, 2024

Copy link
Copy Markdown
Member

Hmm, which build is that?

@titusfortner

Copy link
Copy Markdown
Member Author

I think I figured it out. We need ... instead of .. since we want what exists only in the second branch since trunk & the pr diverted from what parent of PR is.

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

Labels

B-build Includes scripting, bazel and CI integrations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants