import { Connector } from '../connector' ; import * as Winston from 'winston' ; test ( 'Simple test' , async ( ) => { let c ; let logger = new Winston . Logger ( { transports : [ new Winston . transports . Console ( ) ] } ) ; logger . info = console . log ; logger . debug = console . log ; logger . error = console . log ; logger . warn = console . log ; c = new Connector ( logger ) ; await c . init ( { core : { host : '127.0.0.1' , port : 3000 , watchdog : false } , device : { deviceId : 'JestTest' , deviceToken : '1234' } , process : { unsafeSSL : true , certificates : [ ] } , mos : { self : { mosID : 'test.tv.automation' , acceptsConnections : true , profiles : { '0' : true , '1' : true , '2' : true , '3' : false , '4' : false , '5' : false , '6' : false , '7' : false } } } } ) ; expect ( c ) . toBeInstanceOf ( Connector ) ; await c . dispose ( ) ; expect ( 1 ) . toEqual ( 1 ) ; } ) ;