ionic-team / ionic-team/ionic-unit-testing-example

Error: StaticInjectorError(t)[t -> function(){}]:

Aperta
#95 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
TypeScript
Stelle
370
Fork
144
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

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)

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.