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

Add more unit tests for GRPCRoute #2835

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

Conversation

sjberman
Copy link
Contributor

Problem: The change_processor tests were missing GRPCRoute cases.

Solution: Add these test cases to improve coverage of GRPCRoutes.

Closes #2352

Checklist

Before creating a PR, run through this checklist and mark each as complete.

  • I have read the CONTRIBUTING doc
  • I have added tests that prove my fix is effective or that my feature works
  • I have checked that all unit tests pass after adding my changes
  • I have updated necessary documentation
  • I have rebased my branch onto main
  • I will ensure my PR is targeting the main branch and pulling from my branch from my own fork

Release notes

If this PR introduces a change that affects users and needs to be mentioned in the release notes,
please add a brief note that summarizes the change.


Problem: The change_processor tests were missing GRPCRoute cases.

Solution: Add these test cases to improve coverage of GRPCRoutes.
@sjberman sjberman requested a review from a team as a code owner November 27, 2024 15:00
@github-actions github-actions bot added the tests Pull requests that update tests label Nov 27, 2024
Copy link

codecov bot commented Nov 27, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.86%. Comparing base (f56f525) to head (3a8a514).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2835   +/-   ##
=======================================
  Coverage   89.86%   89.86%           
=======================================
  Files         107      107           
  Lines       10997    10997           
  Branches       50       50           
=======================================
  Hits         9883     9883           
  Misses       1054     1054           
  Partials       60       60           

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

Copy link
Contributor

@kate-osborn kate-osborn left a comment

Choose a reason for hiding this comment

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

🚀

Copy link
Contributor

@salonichf5 salonichf5 left a comment

Choose a reason for hiding this comment

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

lgtm, just have a small comment

expRouteGR1, expRouteGR2 *graph.L7Route
expRouteTR1, expRouteTR2 *graph.L4Route
gatewayAPICRD, gatewayAPICRDUpdated *metav1.PartialObjectMetadata
routeKey1, routeKey2, grpcRouteKey1, grpcRouteKey2 graph.RouteKey
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: we should rename these keys to httpRouteKey1, just to be consistent

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tests Pull requests that update tests
Projects
Status: 🆕 New
Development

Successfully merging this pull request may close these issues.

Add unit tests for GRPCRoute to change processor test
3 participants