var args = 2 <= arguments.length ? slice.call(arguments, 1) : [];
var channel = arguments[0];
if (channel == null) {
- throw new Error('channel must be specified');
+ throw new Error('Missing required channel argument');
}
return this._send(channel, slice.call(args));
};
it('throws an error when the channel is missing', function() {
assert.throws(function() {
w.webContents.send();
- }, 'channel must be specified');
+ }, 'Missing required channel argument');
assert.throws(function() {
w.webContents.send(null);
- }, 'channel must be specified');
+ }, 'Missing required channel argument');
});
});
});