@@ -32,19 +32,19 @@ describe("HierarchicalMenuComponent", () => {
3232
3333 it ( "should be flat mode " , ( ) => {
3434 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
35- config . menuItemStructure = MenuItemStructure . FLAT ;
36- expect ( config . menuItemStructure ) . toBe ( MenuItemStructure . FLAT ) ;
35+ config . menuItemStructure = "F" ;
36+ expect ( config . menuItemStructure ) . toBe ( "F" ) ;
3737 } ) ;
3838
3939 it ( "should build a hierarchy from a simple flat list" , ( ) => {
4040 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
41- config . menuItemStructure = MenuItemStructure . FLAT ;
41+ config . menuItemStructure = "F" ;
4242 config . add ( { id : "b" , title : "item b ref a" , parentRef : "a" } ) ;
4343 config . add ( { id : "a" , title : "item a" , parentRef : "" } ) ;
4444 config . add ( { id : "c" , title : "item c ref b" , parentRef : "b" } ) ;
4545
4646 componentFixture . componentInstance . config = config ;
47- expect ( config . menuItemStructure ) . toBe ( MenuItemStructure . FLAT ) ;
47+ expect ( config . menuItemStructure ) . toBe ( "F" ) ;
4848
4949 let menuItems : HierarchicalMenuItem [ ] = componentFixture . componentInstance . config . menuItems ;
5050 // only one item or top level item respectively
@@ -57,7 +57,7 @@ describe("HierarchicalMenuComponent", () => {
5757 it ( "should build a little more complex hierarchy from a flat list" , ( ) => {
5858
5959 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
60- config . menuItemStructure = MenuItemStructure . FLAT ;
60+ config . menuItemStructure = "F" ;
6161 config . add ( { title : "menu.personal.section" } ) ;
6262 config . add ( { title : "menu.personal.home" , parentRef : "menu.personal.section" } ) ;
6363 config . add ( { title : "menu.personal.profile" , parentRef : "menu.personal.section" } ) ;
@@ -140,7 +140,7 @@ describe("HierarchicalMenuComponent", () => {
140140
141141 it ( "should have no expanded items" , ( ) => {
142142 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
143- config . menuItemStructure = MenuItemStructure . FLAT ;
143+ config . menuItemStructure = "F" ;
144144 config . add ( { title : "a" } ) ;
145145 config . add ( { title : "b" } ) ;
146146 config . add ( { title : "c" } ) ;
@@ -155,7 +155,7 @@ describe("HierarchicalMenuComponent", () => {
155155
156156 it ( "should have expanded items" , ( ) => {
157157 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
158- config . menuItemStructure = MenuItemStructure . FLAT ;
158+ config . menuItemStructure = "F" ;
159159 config . add ( { title : "a" , expanded : true } ) ;
160160 config . add ( { title : "aa" , parentRef : "a" } ) ;
161161
@@ -176,7 +176,7 @@ describe("HierarchicalMenuComponent", () => {
176176
177177 it ( "should have all parent items expanded" , ( ) => {
178178 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
179- config . menuItemStructure = MenuItemStructure . FLAT ;
179+ config . menuItemStructure = "F" ;
180180 config . add ( { title : "a" } ) ;
181181 config . add ( { title : "aa" , parentRef : "a" } ) ;
182182 config . add ( { title : "aaa" , parentRef : "aa" } ) ;
@@ -203,7 +203,7 @@ describe("HierarchicalMenuComponent", () => {
203203
204204 it ( "should have all parent items collapsed" , ( ) => {
205205 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
206- config . menuItemStructure = MenuItemStructure . FLAT ;
206+ config . menuItemStructure = "F" ;
207207 config . add ( { title : "a" , expanded : true } ) ;
208208 config . add ( { title : "aa" , parentRef : "a" } ) ;
209209
@@ -225,7 +225,7 @@ describe("HierarchicalMenuComponent", () => {
225225
226226 it ( "should expand defined items and close others" , ( ) => {
227227 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
228- config . menuItemStructure = MenuItemStructure . FLAT ;
228+ config . menuItemStructure = "F" ;
229229 config . add ( { title : "a" , expanded : true } ) ;
230230 config . add ( { title : "aa" , parentRef : "a" } ) ;
231231
@@ -250,7 +250,7 @@ describe("HierarchicalMenuComponent", () => {
250250
251251 it ( "should expand defined items instantly and dont touch existing others" , ( ) => {
252252 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
253- config . menuItemStructure = MenuItemStructure . FLAT ;
253+ config . menuItemStructure = "F" ;
254254 config . add ( { title : "a" , expanded : true } ) ;
255255 config . add ( { title : "aa" , parentRef : "a" } ) ;
256256
@@ -279,7 +279,7 @@ describe("HierarchicalMenuComponent", () => {
279279
280280 it ( "should expand defined items on rebuild" , ( ) => {
281281 let config : HierarchicalMenuConfig = new HierarchicalMenuConfig ( ) ;
282- config . menuItemStructure = MenuItemStructure . FLAT ;
282+ config . menuItemStructure = "F" ;
283283 config . add ( { title : "a" , expanded : true } ) ;
284284 config . add ( { title : "aa" , parentRef : "a" } ) ;
285285
0 commit comments