import { unsafeAlphanumeric } from './random' ; describe ( '"unsafeAlphanumeric"' , ( ) => { it ( 'should generate string of length 32 as default' , ( ) => { const maxLength = 32 ; expect ( unsafeAlphanumeric ( maxLength ) . length ) . toBe ( maxLength ) ; } ) ; it ( 'should generate string for the given length' , ( ) => { const maxLength = 10 ; expect ( unsafeAlphanumeric ( maxLength ) . length ) . toBe ( maxLength ) ; } ) ; } ) ;