Open lvjp opened 1 month ago
The changes made in this pull request focus on improving the organization and clarity of the test cases in the jwt/jwt_test.go
file, particularly for JWT handling. The TestJwtFromHeader
function has been updated to include sub-tests for better structure, while the jwt/utils.go
file has seen a modification in the jwtFromHeader
function to enforce a space between the authentication scheme and the token. Overall, the modifications enhance the readability and maintainability of the code without altering any core functionality.
File | Change Summary |
---|---|
jwt/jwt_test.go | Restructured test cases in TestJwtFromHeader to use sub-tests; improved organization and clarity. TestJwtFromCookie , TestJwkFromServer , and TestJwkFromServers remain unchanged. |
jwt/utils.go | Modified jwtFromHeader function to enforce a space between the authentication scheme and the token; other functions remain unchanged. |
Hop, hop, hooray, the tests are now neat,
With sub-tests to guide, they can't be beat!
A space for the scheme, a token in line,
In the world of JWTs, everything's fine!
So let’s celebrate with a joyful cheer,
For clearer code brings us all good cheer! 🐇✨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Summary by CodeRabbit
New Features
Bug Fixes