"use strict";var cov_h9a3mwwe1=function(){var path="/Users/josh.burman/Projects/braid/dist/server/test/channelBase.spec.js";var hash="5625eb7f43e1e44a45a277057925e25a130607b2";var Function=function(){}.constructor;var global=new Function("return this")();var gcv="__coverage__";var coverageData={path:"/Users/josh.burman/Projects/braid/dist/server/test/channelBase.spec.js",statementMap:{"0":{start:{line:2,column:0},end:{line:2,column:62}},"1":{start:{line:3,column:22},end:{line:3,column:56}},"2":{start:{line:4,column:21},end:{line:4,column:53}},"3":{start:{line:5,column:13},end:{line:5,column:35}},"4":{start:{line:6,column:12},end:{line:6,column:28}},"5":{start:{line:7,column:22},end:{line:7,column:49}},"6":{start:{line:8,column:0},end:{line:27,column:3}},"7":{start:{line:9,column:15},end:{line:9,column:29}},"8":{start:{line:10,column:18},end:{line:10,column:49}},"9":{start:{line:11,column:19},end:{line:11,column:40}},"10":{start:{line:12,column:15},end:{line:12,column:111}},"11":{start:{line:13,column:17},end:{line:13,column:57}},"12":{start:{line:14,column:4},end:{line:16,column:7}},"13":{start:{line:15,column:8},end:{line:15,column:45}},"14":{start:{line:17,column:4},end:{line:20,column:7}},"15":{start:{line:18,column:21},end:{line:18,column:46}},"16":{start:{line:19,column:8},end:{line:19,column:53}},"17":{start:{line:21,column:4},end:{line:23,column:7}},"18":{start:{line:22,column:8},end:{line:22,column:40}},"19":{start:{line:24,column:4},end:{line:26,column:7}},"20":{start:{line:25,column:8},end:{line:25,column:57}}},fnMap:{"0":{name:"(anonymous_0)",decl:{start:{line:8,column:29},end:{line:8,column:30}},loc:{start:{line:8,column:41},end:{line:27,column:1}},line:8},"1":{name:"(anonymous_1)",decl:{start:{line:14,column:47},end:{line:14,column:48}},loc:{start:{line:14,column:59},end:{line:16,column:5}},line:14},"2":{name:"(anonymous_2)",decl:{start:{line:17,column:41},end:{line:17,column:42}},loc:{start:{line:17,column:53},end:{line:20,column:5}},line:17},"3":{name:"(anonymous_3)",decl:{start:{line:21,column:31},end:{line:21,column:32}},loc:{start:{line:21,column:43},end:{line:23,column:5}},line:21},"4":{name:"(anonymous_4)",decl:{start:{line:24,column:37},end:{line:24,column:38}},loc:{start:{line:24,column:49},end:{line:26,column:5}},line:24}},branchMap:{},s:{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0},f:{"0":0,"1":0,"2":0,"3":0,"4":0},b:{},_coverageSchema:"43e27e138ebf9cfc5966b082cf9a028302ed4184"};var coverage=global[gcv]||(global[gcv]={});if(coverage[path]&&coverage[path].hash===hash){return coverage[path];}coverageData.hash=hash;return coverage[path]=coverageData;}();cov_h9a3mwwe1.s[0]++;Object.defineProperty(exports,"__esModule",{value:true});const channelBase_1=(cov_h9a3mwwe1.s[1]++,require("../channels/channelBase"));const clientBase_1=(cov_h9a3mwwe1.s[2]++,require("../clients/clientBase"));var expect=(cov_h9a3mwwe1.s[3]++,require('chai').expect);var sinon=(cov_h9a3mwwe1.s[4]++,require('sinon'));var WebSocketClient=(cov_h9a3mwwe1.s[5]++,require('websocket').client);cov_h9a3mwwe1.s[6]++;describe('channelBaseClass',function(){cov_h9a3mwwe1.f[0]++;var name=(cov_h9a3mwwe1.s[7]++,'test channel');var channel=(cov_h9a3mwwe1.s[8]++,new channelBase_1.default(name));var wsClient=(cov_h9a3mwwe1.s[9]++,new WebSocketClient());var data=(cov_h9a3mwwe1.s[10]++,{'client':'mhs','client_type':'site','user_id':125,'user_type':'user','channel':name});var client=(cov_h9a3mwwe1.s[11]++,new clientBase_1.default(data,wsClient));cov_h9a3mwwe1.s[12]++;it('should create a class of ChannelBase',function(){cov_h9a3mwwe1.f[1]++;cov_h9a3mwwe1.s[13]++;expect(channel.id).to.be.equal(name);});cov_h9a3mwwe1.s[14]++;it('should add a client to channel',function(){cov_h9a3mwwe1.f[2]++;var result=(cov_h9a3mwwe1.s[15]++,channel.addClient(client));cov_h9a3mwwe1.s[16]++;expect(result.status).to.be.equal('success');});cov_h9a3mwwe1.s[17]++;it('should find a client',function(){cov_h9a3mwwe1.f[3]++;cov_h9a3mwwe1.s[18]++;channel.clientExists(client.id);});cov_h9a3mwwe1.s[19]++;it('should broadcase a message',function(){cov_h9a3mwwe1.f[4]++;cov_h9a3mwwe1.s[20]++;channel.broadcastMessage(client,'test message');});});//# sourceMappingURL=channelBase.spec.js.map