add failing spec for undefined accelerator

This commit is contained in:
Zeke Sikelianos 2016-03-17 16:09:16 -07:00
parent 67db92d500
commit 87395cdef8

View file

@ -32,6 +32,17 @@ describe('menu module', function() {
]);
});
it('does not throw exceptions for undefined/null values', function() {
assert.doesNotThrow(function(){
Menu.buildFromTemplate([
{
label: 'text',
accelerator: undefined
}
]);
});
});
describe('Menu.buildFromTemplate should reorder based on item position specifiers', function() {
it('should position before existing item', function() {
var menu = Menu.buildFromTemplate([