GUI -- Fixed broken glyph unit tests.
Change-Id: Ife32db43b819de10e4ad094e62f42682e9105b5e
Showing
2 changed files
with
19 additions
and
3 deletions
... | @@ -169,8 +169,9 @@ | ... | @@ -169,8 +169,9 @@ |
169 | } | 169 | } |
170 | 170 | ||
171 | function addRow() { | 171 | function addRow() { |
172 | - if (currentRow.select('div').empty()) { return null; } | 172 | + if (currentRow.select('div').empty()) { |
173 | - else { | 173 | + return null; |
174 | + } else { | ||
174 | panel.append('br'); | 175 | panel.append('br'); |
175 | currentRow = panel.append('div').classed('tbar-row', true); | 176 | currentRow = panel.append('div').classed('tbar-row', true); |
176 | } | 177 | } | ... | ... |
... | @@ -20,7 +20,7 @@ | ... | @@ -20,7 +20,7 @@ |
20 | describe('factory: fw/svg/glyph.js', function() { | 20 | describe('factory: fw/svg/glyph.js', function() { |
21 | var $log, fs, gs, d3Elem, svg; | 21 | var $log, fs, gs, d3Elem, svg; |
22 | 22 | ||
23 | - var numBaseGlyphs = 19, | 23 | + var numBaseGlyphs = 22, |
24 | vbBird = '352 224 113 112', | 24 | vbBird = '352 224 113 112', |
25 | vbGlyph = '0 0 110 110', | 25 | vbGlyph = '0 0 110 110', |
26 | vbBadge = '0 0 10 10', | 26 | vbBadge = '0 0 10 10', |
... | @@ -41,6 +41,9 @@ describe('factory: fw/svg/glyph.js', function() { | ... | @@ -41,6 +41,9 @@ describe('factory: fw/svg/glyph.js', function() { |
41 | details: longPrefix + 'M16.9', | 41 | details: longPrefix + 'M16.9', |
42 | ports: 'M98,9.2H79.6c', | 42 | ports: 'M98,9.2H79.6c', |
43 | map: 'M95.8,9.2H14.2c-2.8,0-5,2.2-5,5v66', | 43 | map: 'M95.8,9.2H14.2c-2.8,0-5,2.2-5,5v66', |
44 | + resetZoom: 'M86.4,81', | ||
45 | + nextIntent: 'M88.1,55.7', | ||
46 | + prevIntent: 'M22.5,55.6', | ||
44 | 47 | ||
45 | uiAttached: 'M2,2.5a.5,.5', | 48 | uiAttached: 'M2,2.5a.5,.5', |
46 | checkMark: 'M2.6,4.5c0', | 49 | checkMark: 'M2.6,4.5c0', |
... | @@ -164,6 +167,18 @@ describe('factory: fw/svg/glyph.js', function() { | ... | @@ -164,6 +167,18 @@ describe('factory: fw/svg/glyph.js', function() { |
164 | gs.init(); | 167 | gs.init(); |
165 | verifyGlyphLoadedInCache('map', vbGlyph); | 168 | verifyGlyphLoadedInCache('map', vbGlyph); |
166 | }); | 169 | }); |
170 | + it('should load the resetZoom glyph', function () { | ||
171 | + gs.init(); | ||
172 | + verifyGlyphLoadedInCache('resetZoom', vbGlyph); | ||
173 | + }); | ||
174 | + it('should load the nextIntent glyph', function () { | ||
175 | + gs.init(); | ||
176 | + verifyGlyphLoadedInCache('nextIntent', vbGlyph); | ||
177 | + }); | ||
178 | + it('should load the prevIntent glyph', function () { | ||
179 | + gs.init(); | ||
180 | + verifyGlyphLoadedInCache('prevIntent', vbGlyph); | ||
181 | + }); | ||
167 | it('should load the uiAttached glyph', function() { | 182 | it('should load the uiAttached glyph', function() { |
168 | gs.init(); | 183 | gs.init(); |
169 | verifyGlyphLoadedInCache('uiAttached', vbBadge); | 184 | verifyGlyphLoadedInCache('uiAttached', vbBadge); | ... | ... |
-
Please register or login to post a comment