yyqdbngt opened a new pull request, #3881:
URL: https://github.com/apache/rocketmq-dashboard/pull/3881

   ### Motivation
   
   The auth session storage helpers had five tests covering the happy path, 
cookie independence, and clearing, but left null/zero user ids, the false admin 
flag, and empty-storage behavior unasserted. This PR grows the suite from 5 to 
10 cases.
   
   ### Changes
   
   - Persisting a `null` user id removes the stored id key instead of writing 
the literal string `null`.
   - A numeric zero user id persists and restores as `0` (never treated as 
absent).
   - Only the literal `true` flag yields `admin: true`; `false` and arbitrary 
flag text both read back as `false`.
   - Completely empty storage reads back an all-`null` session.
   - Clearing an already-empty session does not throw.
   
   ### Verification
   
   - `vitest run src/stores/authStorage.test.ts`: 10/10 passed
   - `tsc --noEmit`: clean
   - `eslint src/stores/authStorage.test.ts`: clean


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to