|
12 | 12 | test.equals(p.fileName, '00-colors'); |
13 | 13 | test.equals(p.jsonFileData.d, 123); |
14 | 14 | test.equals(p.patternName, 'colors'); |
| 15 | + test.equals(p.patternDisplayName, 'Colors'); |
15 | 16 | test.equals(p.patternLink, '00-atoms-00-global-00-colors/00-atoms-00-global-00-colors.html'); |
16 | 17 | test.equals(p.patternGroup, 'atoms'); |
17 | 18 | test.equals(p.patternSubGroup, 'global'); |
|
24 | 25 | test.equals(p.lineageR.length, 0); |
25 | 26 | test.equals(p.lineageRIndex.length, 0); |
26 | 27 | test.done(); |
| 28 | + }, |
| 29 | + 'test oPattern capitalizes patternDisplayName correctly' : function(test){ |
| 30 | + var p = new of.oPattern('source/_patterns/00-atoms/00-global/00-colors-alt.mustache', '00-atoms/00-global', '00-colors-alt.mustache', { d: 123}); |
| 31 | + test.equals(p.patternName, 'colors-alt'); |
| 32 | + test.equals(p.patternDisplayName, 'Colors Alt'); |
| 33 | + test.done(); |
27 | 34 | } |
28 | 35 | }; |
29 | 36 |
|
|
37 | 44 | test.equals(b.patternItems.length, 0); |
38 | 45 | test.equals(b.patternItemsIndex.length, 0); |
39 | 46 | test.done(); |
| 47 | + }, |
| 48 | + 'test oBucket capitalizes bucketNameUC' : function(test){ |
| 49 | + var b = new of.oBucket('page-templates'); |
| 50 | + test.equals(b.bucketNameLC, 'page-templates'); |
| 51 | + test.equals(b.bucketNameUC, 'Page Templates'); |
| 52 | + test.done(); |
40 | 53 | } |
41 | 54 | }; |
42 | 55 |
|
43 | 56 | exports['oNavItem initialization'] = { |
44 | 57 | 'test oNavItem initializes correctly' : function(test){ |
45 | 58 | var ni = new of.oNavItem('test'); |
46 | 59 | test.equals(ni.sectionNameLC, 'test'); |
| 60 | + test.equals(ni.sectionNameUC, 'Test'); |
47 | 61 | test.equals(ni.navSubItems.length, 0); |
48 | 62 | test.equals(ni.navSubItemsIndex.length, 0); |
49 | 63 | test.done(); |
| 64 | + }, |
| 65 | + 'test oNavItem correctly capitalizes sectionNameUC' : function(test){ |
| 66 | + var ni = new of.oNavItem('global-concepts'); |
| 67 | + test.equals(ni.sectionNameLC, 'global-concepts'); |
| 68 | + test.equals(ni.sectionNameUC, 'Global Concepts'); |
| 69 | + test.done(); |
50 | 70 | } |
51 | 71 | }; |
52 | | - |
| 72 | + |
53 | 73 | exports['oSubNavItem initialization'] = { |
54 | 74 | 'test oSubNavItem initializes correctly' : function(test){ |
55 | 75 | var sni = new of.oNavSubItem('test'); |
56 | 76 | test.equals(sni.patternName, 'Test'); |
57 | 77 | test.equals(sni.patternPath, ''); |
58 | 78 | test.equals(sni.patternPartial, ''); |
59 | 79 | test.done(); |
| 80 | + }, |
| 81 | + 'test oSubNavItem capitalizes patternName' : function(test){ |
| 82 | + var sni = new of.oNavSubItem('nav button'); |
| 83 | + test.equals(sni.patternName, 'Nav Button'); |
| 84 | + test.done(); |
60 | 85 | } |
61 | 86 | }; |
62 | 87 |
|
|
0 commit comments