-
Notifications
You must be signed in to change notification settings - Fork 145
Description
wrote same code as in page1.spec.ts still getting this error.
Error: StaticInjectorError(t)[t -> function(){}]:
StaticInjectorError(Platform: core)[t -> function(){}]:
NullInjectorError: No provider for function(){}!
error properties: Object({ ngTempTokenPath: null, ngTokenPath: [ 't', Function ], ngDebugContext: t({ view: Object({ def: Object({ factory: Function, nodeFlags: 33669121, rootNodeFlags: 33554433, nodeMatchedQueries: 0, flags: 0, nodes: [ Object({ nodeIndex: 0, parent: null, renderParent: null, bindingIndex: 0, outputIndex: 0, checkIndex: 0, flags: 33554433, childFlags: 114688, directChildFlags: 114688, childMatchedQueries: 0, matchedQueries: Object({ }), matchedQueryIds: 0, references: Object({ }), ngContentIndex: null, childCount: 1, bindings: [ ], bindingFlags: 0, outputs: [ ], element: Object({ ns: '', name: 'signup', attrs: [ ], template: null, componentProvider: Object({ nodeIndex: 1, parent: , renderParent: , bindingIndex: 0, outputIndex: 0, checkIndex: 1, flags: 114688, childFlags: 0, directChildFlags: 0, childMatchedQueries: 0, matchedQueries: Object, matchedQueryIds: 0, references: Object, ngContentIndex: -1, childCount: 0, bindings: ...
at t.get (webpack:///node_modules/@angular/core/esm5/core.js:1003 <- test-config/karma-test-shim.js:45:142)
at webpack:///node_modules/@angular/core/esm5/core.js:1301 <- test-config/karma-test-shim.js:52:2444
at yt (webpack:///node_modules/@angular/core/esm5/core.js:1243 <- test-config/karma-test-shim.js:52:2462)
at t.get (webpack:///node_modules/@angular/core/esm5/core.js:1111 <- test-config/karma-test-shim.js:52:1621) at webpack:///node_modules/@angular/core/esm5/core.js:1301 <- test-config/karma-test-shim.js:52:2444
at yt (webpack:///node_modules/@angular/core/esm5/core.js:1243 <- test-config/karma-test-shim.js:52:2462)
at t.get (webpack:///node_modules/@angular/core/esm5/core.js:1111 <- test-config/karma-test-shim.js:52:1621) at hi (webpack:///node_modules/@angular/core/esm5/core.js:10896 <- test-config/karma-test-shim.js:298:683)