import { getQuery } from '@src/vue-use-kit' ; describe ( 'getQuery' , ( ) => { it ( 'should throw when no min or max value is provided' , ( ) => { const t = ( ) => getQuery ( ) ; expect ( t ) . toThrow ( Error ) ; } ) ; it ( 'should return the expected queries' , ( ) => { const maxWidthQuery = getQuery ( 0 , 500 ) ; expect ( maxWidthQuery ) . not . toContain ( 'min-width' ) ; expect ( maxWidthQuery ) . toContain ( 'max-width' ) ; const minAndMaxWidthQuery = getQuery ( 500 , 1024 ) ; expect ( minAndMaxWidthQuery ) . toContain ( 'min-width' ) ; expect ( minAndMaxWidthQuery ) . toContain ( 'max-width' ) ; const minWidthQuery = getQuery ( 1024 ) ; expect ( minWidthQuery ) . toContain ( 'min-width' ) ; expect ( minWidthQuery ) . not . toContain ( 'max-width' ) ; } ) ; } ) ;