There are plenty of questions are existed regarding to this error and I have verified almost all but not getting resolved with those answers and suggestions. So please apologize for this.
I have tried to test an angular component by using Jasmine and Karma. Initially through 'ng test' I got an error like "Uncaught NetworkError: Failed to execute 'send' on 'XMLHttpRequest': Failed to load 'ng:///DynamicTestModule/SearchActionsComponent.ngfactory.js'. thrown"
Afetr through 'ng test --source-map=false' I got error like this "Uncaught TypeError: Cannot read property 'length' of undefined". Error coming after fixture.detectChanges() as per my observation but I am not sure that exact reason. So could any one please help me.