Fix flaky router private key PEM test#378
Conversation
Signed-off-by: CYJiang <googs1025@gmail.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Updates JWT private key PEM unit test to compare RSA private keys by value rather than by pointer/reference, aligning the assertion with how parsed keys are represented.
Changes:
- Replace
assert.Equalwith(*rsa.PrivateKey).Equal-based assertion for private key comparison.
There was a problem hiding this comment.
Code Review
This pull request updates a test assertion in pkg/router/jwt_test.go to compare private keys using the Equal method instead of assert.Equal. No review comments were provided, and there is no additional feedback.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #378 +/- ##
===========================================
+ Coverage 47.57% 58.00% +10.43%
===========================================
Files 30 34 +4
Lines 2819 3181 +362
===========================================
+ Hits 1341 1845 +504
+ Misses 1338 1151 -187
- Partials 140 185 +45
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Fixes a flaky router test seen in coverage:
https://github.com/volcano-sh/agentcube/actions/runs/26986069745/job/79635856049
The parsed RSA key is equivalent, but CRT internals can differ by leading zero bytes. Use rsa.PrivateKey.Equal for the assertion.