Skip to content

Commit e0a4f09

Browse files
committed
test(app): fix karma test for app to include change detector
1 parent 35dd0ed commit e0a4f09

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

ionic/components/app/test/app.spec.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,23 +89,28 @@ describe('IonicApp', () => {
8989
var app: IonicApp;
9090
var config: Config;
9191
var platform: Platform;
92+
var _cd: any;
9293

9394
function mockNav(): Nav {
94-
return new Nav(null,null,null,config,null,null,null,null,null,null);
95+
return new Nav(null, null, null, config, null, null, null, null, null, null);
9596
}
9697

9798
function mockTabs(): Tabs {
9899
return new Tabs(null, null, null, config, null, null, null);
99100
}
100101

101102
function mockTab(parentTabs: Tabs): Tab {
102-
return new Tab(parentTabs,null,config,null,null,null,null,null,null);
103+
return new Tab(parentTabs, app, config, null, null, null, null, null, null, _cd);
103104
}
104105

105106
beforeEach(() => {
106107
config = new Config();
107108
platform = new Platform();
108109
app = new IonicApp(config, null, platform);
110+
_cd = {
111+
reattach: function(){},
112+
detach: function(){}
113+
};
109114
});
110115

111116
});

0 commit comments

Comments
 (0)