File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -39,10 +39,9 @@ describe('MockDataLoader', () => {
3939 it ( 'should detect CachedMetadata not previously loaded, even if it is a clone of a loaded file' , ( ) => {
4040 const data1 = MockDataLoader . get ( 'one_task' ) ;
4141
42- // Prefer `structuredClone(…)` over `JSON.parse(JSON.stringify(…))` to create a deep clone.
43- // But structuredClone() is not avaialble in Jest.
44- // sonar-disable-next-line typescript:S7784
45- const clonedMetadata = JSON . parse ( JSON . stringify ( data1 . cachedMetadata ) ) ;
42+ // typescript:S7784 Prefer `structuredClone(…)` over `JSON.parse(JSON.stringify(…))` to create a deep clone.
43+ // But structuredClone() is not available in Jest.
44+ const clonedMetadata = JSON . parse ( JSON . stringify ( data1 . cachedMetadata ) ) ; // NOSONAR
4645 expect ( clonedMetadata ) . toStrictEqual ( data1 . cachedMetadata ) ;
4746 const t = ( ) => {
4847 MockDataLoader . findCachedMetaData ( clonedMetadata ) ;
You can’t perform that action at this time.
0 commit comments