TypeError:无法在Receiver.unmask

时间:2017-04-19 16:55:39

标签: angular karma-runner karma-jasmine angular-cli

在Chrome浏览器中启动业力,然后在角度2中运行业力进行单位测试时,用一个错误关闭自己:

  

19 04 2017 19:14:27.848:ERROR [karma]:TypeError:无法读取未定义的属性'unmask'
      在Receiver.unmask(C:\ Projects \ Git Repo \ TDP \ switchmanager \ src \ SwitchDesigner \ node_modules \ engine.io \ node_modules \ ws \ lib \ Receiver.js:306:46)
      在Receiver.finish(C:\ Projects \ Git Repo \ TDP \ switchmanager \ src \ SwitchDesigner \ node_modules \ engine.io \ node_modules \ ws \ lib \ Receiver.js:505:25)
      在Receiver.expectHandler(C:\ Projects \ Git Repo \ TDP \ switchmanager \ src \ SwitchDesigner \ node_modules \ engine.io \ node_modules \ ws \ lib \ Receiver.js:493:33)
      在Receiver.add(C:\ Projects \ Git Repo \ TDP \ switchmanager \ src \ SwitchDesigner \ node_modules \ engine.io \ node_modules \ ws \ lib \ Receiver.js:103:24)       在Socket.realHandler(C:\ Projects \ Git Repo \ TDP \ switchmanager \ src \ SwitchDesigner \ node_modules \ engine.io \ node_modules \ ws \ lib \ WebSocket.js:825:20)
      在emitOne(events.js:96:13)
      在Socket.emit(events.js:188:7)
      在readableAddChunk(_stream_readable.js:176:18)
      在Socket.Readable.push(_stream_readable.js:134:10)
      在TCP.onread(net.js:548:20)

任何帮助?

1 个答案:

答案 0 :(得分:0)

按照:https://github.com/websockets/ws/issues/1010 请添加bufferutil作为依赖项。