mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
update setBackgroundColor invalid arg test
This commit is contained in:
@@ -56,11 +56,12 @@ describe('BrowserView module', () => {
|
||||
view.setBackgroundColor('#000');
|
||||
});
|
||||
|
||||
it('throws for invalid args', () => {
|
||||
// We now treat invalid args as "no background".
|
||||
it('does not throw for invalid args', () => {
|
||||
view = new BrowserView();
|
||||
expect(() => {
|
||||
view.setBackgroundColor(null as any);
|
||||
}).to.throw(/conversion failure/);
|
||||
view.setBackgroundColor({} as any);
|
||||
}).not.to.throw();
|
||||
});
|
||||
|
||||
// Linux and arm64 platforms (WOA and macOS) do not return any capture sources
|
||||
|
||||
Reference in New Issue
Block a user