Add failing spec for insertCSS
This commit is contained in:
parent
2f5acfedcd
commit
017df93ffa
1 changed files with 9 additions and 0 deletions
|
@ -268,4 +268,13 @@ describe('webContents module', function () {
|
||||||
w.webContents.sendInputEvent({type: 'char', keyCode: 'Z', modifiers: ['shift', 'ctrl']})
|
w.webContents.sendInputEvent({type: 'char', keyCode: 'Z', modifiers: ['shift', 'ctrl']})
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
it('supports inserting CSS', function (done) {
|
||||||
|
w.loadURL('about:blank')
|
||||||
|
w.webContents.insertCSS('body { background-repeat: round; }')
|
||||||
|
w.webContents.executeJavaScript('window.getComputedStyle(document.body).getPropertyValue("background-repeat")', (result) => {
|
||||||
|
assert.equal(result, 'round')
|
||||||
|
done()
|
||||||
|
})
|
||||||
|
})
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue