mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-04 23:20:07 +00:00
refactor: remove any types from batch 18 test files (2 instances)
Fixed final 2 'as any' instances: - formatUtil.test.ts: Used proper type casts for null/undefined test parameters This completes the removal of all 'as any' type assertions from test files. The only remaining match is a false positive in a comment. Total fixed across all batches (13-18): 54 instances
This commit is contained in:
@@ -120,8 +120,12 @@ describe('formatUtil', () => {
|
||||
})
|
||||
|
||||
it('should handle null and undefined gracefully', () => {
|
||||
expect(getMediaTypeFromFilename(null as any)).toBe('image')
|
||||
expect(getMediaTypeFromFilename(undefined as any)).toBe('image')
|
||||
expect(getMediaTypeFromFilename(null as unknown as string)).toBe(
|
||||
'image'
|
||||
)
|
||||
expect(getMediaTypeFromFilename(undefined as unknown as string)).toBe(
|
||||
'image'
|
||||
)
|
||||
})
|
||||
|
||||
it('should handle special characters in filenames', () => {
|
||||
|
||||
Reference in New Issue
Block a user