Skip to content

Go: Enable Testing with RC #3916

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

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

Go: Enable Testing with RC #3916

wants to merge 8 commits into from

Conversation

edlng
Copy link
Collaborator

@edlng edlng commented May 20, 2025

We can add an option on GHA and locally to test our test suites using a release candidate instead of having to compile and build at the beginning.

Example of running on v1.3.4-rc2: https://github.com/valkey-io/valkey-glide/actions/runs/15145956032

Issue link

This Pull Request is linked to issue (URL): closes #3958

Checklist

Before submitting the PR make sure the following are checked:

  • This Pull Request is related to one issue.
  • Commit message has a detailed description of what changed and why.
  • Tests are added or updated.
  • CHANGELOG.md and documentation files are updated.
  • Destination branch is correct - main or release
  • Create merge commit if merging release branch into main, squash otherwise.
    Signed-off-by: Edward Liang [email protected]Signed-off-by: Edward Liang [email protected]

edlng added 3 commits May 20, 2025 10:31
Signed-off-by: Edward Liang <[email protected]>
Signed-off-by: Edward Liang <[email protected]>
Signed-off-by: Edward Liang <[email protected]>
@edlng edlng self-assigned this May 20, 2025
@edlng edlng requested a review from a team as a code owner May 20, 2025 18:03
@edlng edlng added the go golang wrapper label May 20, 2025
Signed-off-by: Edward Liang <[email protected]>
Signed-off-by: Edward Liang <[email protected]>
@edlng edlng marked this pull request as ready for review May 20, 2025 19:23
@yipin-chen yipin-chen requested a review from Yury-Fridlyand May 21, 2025 15:26
Copy link
Collaborator

@yipin-chen yipin-chen left a comment

Choose a reason for hiding this comment

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

LGTM.
Have you verified your changes?

@edlng
Copy link
Collaborator Author

edlng commented May 22, 2025

LGTM. Have you verified your changes?

Yes, I've provided a GHA run in the description that tests using an RC. The automatic GHA checks when updating or opening a PR also verify that it can compile+build the code instead

Copy link
Collaborator

@Yury-Fridlyand Yury-Fridlyand left a comment

Choose a reason for hiding this comment

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

I though it will be a part of go CD pipeline, but this idea is even better. We can run new tests with an old release.

- name: Install & build & test
working-directory: go
if: ${{ github.event.inputs.rc-test != 'true' }}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
if: ${{ github.event.inputs.rc-test != 'true' }}

And this step will run tests (yes, build will be odd for RC testing)

# Checkout release branch
echo "Checking out $BRANCH branch..."
git fetch origin $BRANCH
git checkout $BRANCH
Copy link
Collaborator

Choose a reason for hiding this comment

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

No need to checkout a branch. GHA already has a branch selector, but we can run new tests with an old RC with your script.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I think it might be required. Go mod tidy doesn't seem to work too well when things have been moved around or added. Adding the branch makes it more stable

Ex. trying to run 1.3.4-rc2 on more recent branches

go.mod has been updated
go: finding module for package github.com/valkey-io/valkey-glide/go/api/server-modules/glidejson
go: finding module for package github.com/valkey-io/valkey-glide/go/api/server-modules/glidejson/options
go: github.com/valkey-io/valkey-glide/go-test-rc/api/server-modules/glidejson imports
        github.com/valkey-io/valkey-glide/go/api/server-modules/glidejson/options: module github.com/valkey-io/valkey-glide/go@latest found (v1.3.4), but does not contain package github.com/valkey-io/valkey-glide/go/api/server-modules/glidejson/options
go: github.com/valkey-io/valkey-glide/go-test-rc/integTest tested by
        github.com/valkey-io/valkey-glide/go-test-rc/integTest.test imports
        github.com/valkey-io/valkey-glide/go/api/server-modules/glidejson: module github.com/valkey-io/valkey-glide/go@latest found (v1.3.4), but does not contain package github.com/valkey-io/valkey-glide/go/api/server-modules/glidejson

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

but then again if we were to apply the patch and then switch to another release branch, conflicts start happening 😨

edlng added 2 commits May 23, 2025 14:59
Signed-off-by: Edward Liang <[email protected]>
Signed-off-by: Edward Liang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
go golang wrapper
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Go: RC Testing
3 participants