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

test: cleanup roundrobin tests to use stubserver #5236

Merged
merged 1 commit into from
Mar 16, 2022

Conversation

easwars
Copy link
Contributor

@easwars easwars commented Mar 10, 2022

Summary of changes:

  • Delete the existing tests in balancer/roundrobin/roundrobin_test.go and move them to test/roundrobin_test.go.
    • We are not testing anything in these tests which are internal to the roundrobin package. So, making these tests e2e sounds like a better option.
  • Get rid of the custom implementation of TestService, and use the stubserver package instead.
  • Add some test helpers to make the tests more readable.

Old tests were 591 lines long, the new one is 411 lines long.

#stubserver-everywhere

RELEASE NOTES: none

@easwars easwars added the Type: Internal Cleanup Refactors, etc label Mar 10, 2022
@easwars easwars added this to the 1.46 Release milestone Mar 10, 2022
@easwars easwars added Type: Testing and removed Type: Internal Cleanup Refactors, etc labels Mar 10, 2022
@menghanl menghanl assigned easwars and unassigned menghanl Mar 15, 2022
@easwars easwars merged commit 94ee386 into grpc:master Mar 16, 2022
@easwars easwars deleted the roundrobin_test branch March 16, 2022 00:01
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 12, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants