问题 I am trying to write unit tests for Angular4 app using karma after this I am getting error at TestBed.createComponent(ServicesComponent) so none of the test cases are being executed, and TypeError: this.expiry.last is not a function at Idle.Array.concat.Idle.watch... There is a lot of stuff written in the constructor(in which there are service calls being made and also Idle functionality was written), How would the test cases should be written for that? This is my spec file, Idle functions