fix: potential crash when setting vibrancy (#29677)
This commit is contained in:
parent
81795744cf
commit
2ae7e04598
2 changed files with 11 additions and 4 deletions
|
@ -1609,6 +1609,13 @@ describe('BrowserWindow module', () => {
|
|||
w.setVibrancy('' as any);
|
||||
}).to.not.throw();
|
||||
});
|
||||
|
||||
it('does not crash if vibrancy is set to an invalid value', () => {
|
||||
const w = new BrowserWindow({ show: false });
|
||||
expect(() => {
|
||||
w.setVibrancy('i-am-not-a-valid-vibrancy-type' as any);
|
||||
}).to.not.throw();
|
||||
});
|
||||
});
|
||||
|
||||
ifdescribe(process.platform === 'darwin')('trafficLightPosition', () => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue