@@ -37,19 +37,25 @@ describe('Dithering Module', () => {
3737 return
3838 }
3939 stdout . on ( 'data' , ( chunk : Buffer ) => chunks . push ( chunk ) )
40- stdout . on ( 'end' , ( ) => { resolve ( Buffer . concat ( chunks ) ) ; } )
40+ stdout . on ( 'end' , ( ) => {
41+ resolve ( Buffer . concat ( chunks ) )
42+ } )
4143 stdout . on ( 'error' , reject )
4244 } )
4345 } )
44- } )
46+ } , 15000 )
4547
4648 // ==========================================================================
4749 // Constants - Test that module exports expected values
4850 // ==========================================================================
4951
5052 describe ( 'SUPPORTED_METHODS' , ( ) => {
5153 it ( 'exports array of supported dithering methods' , ( ) => {
52- expect ( SUPPORTED_METHODS ) . toEqual ( [ 'floyd-steinberg' , 'ordered' , 'threshold' ] )
54+ expect ( SUPPORTED_METHODS ) . toEqual ( [
55+ 'floyd-steinberg' ,
56+ 'ordered' ,
57+ 'threshold' ,
58+ ] )
5359 } )
5460 } )
5561
@@ -113,7 +119,9 @@ describe('Dithering Module', () => {
113119
114120 it ( 'falls back to defaults when invalid method provided' , ( ) => {
115121 // NOTE: Intentionally testing with invalid input - type assertion required
116- const result = validateDitheringOptions ( { method : 'invalid-method' as DitheringMethod } )
122+ const result = validateDitheringOptions ( {
123+ method : 'invalid-method' as DitheringMethod ,
124+ } )
117125 expect ( result . method ) . toBe ( 'floyd-steinberg' )
118126 } )
119127
@@ -406,11 +414,13 @@ describe('Dithering Module', () => {
406414 return
407415 }
408416 stdout . on ( 'data' , ( chunk : Buffer ) => chunks . push ( chunk ) )
409- stdout . on ( 'end' , ( ) => { resolve ( Buffer . concat ( chunks ) ) ; } )
417+ stdout . on ( 'end' , ( ) => {
418+ resolve ( Buffer . concat ( chunks ) )
419+ } )
410420 stdout . on ( 'error' , reject )
411421 } )
412422 } )
413- } )
423+ } , 15000 )
414424
415425 it ( 'produces 1-bit BW images under 50KB for 800x480' , async ( ) => {
416426 const result = await applyDithering ( largeTestImage , {
0 commit comments