Closed MichaelGoberling closed 1 year ago
Merging #112 (e3ec3b8) into master (b11c0d8) will not change coverage. The diff coverage is
100.00%
.
@@ Coverage Diff @@
## master #112 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 8 9 +1
Lines 428 481 +53
Branches 58 68 +10
=========================================
+ Hits 428 481 +53
Impacted Files | Coverage Δ | |
---|---|---|
src/ValidationCache.js | 100.00% <100.00%> (ø) |
|
src/ims.js | 100.00% <100.00%> (ø) |
|
src/index.js | 100.00% <100.00%> (ø) |
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more
Description
This PR adds the validation caching functionality currently used by the shared validator actions.
It also adds a new function that allows implementers to validate a token against an allow-list of IMS clients.
This should not be breaking as the
validateToken
call should return the same data as before. The oldvalidateToken
function has been moved to a private function_validateToken
, and has been slightly modified to work with ValidationCache.Motivation and Context
To use in the App Builder Delete Service and allow others to cache validations / invalidations. To allow validating a token against an allow-list.
How Has This Been Tested?
Ran
npm run test
, branch tested against Delete Service ims-auth PRScreenshots (if appropriate):
Types of changes
Checklist: