import { ddl } from '../ddl' ; describe ( 'ddl' , ( ) => { it ( 'fails over when http2 is not supported' , async ( ) => { const session = { request : ( ) => { return { on : ( eventType , cb ) => { if ( eventType === 'error' ) { cb ( new Error ( 'itsbad' ) ) ; } } } ; } } ; const command = { ksql : "select * from cars where ROWKEY='fd'GROUP BY id ;" } ; const result = await ddl ( session , command ) ; expect ( result . error ) . toEqual ( true ) ; } ) ; } ) ;