Fix capturePage() spec.
This commit is contained in:
parent
0a84c30d3b
commit
cfeeec37eb
1 changed files with 3 additions and 2 deletions
|
@ -77,10 +77,11 @@ describe 'browser-window module', ->
|
||||||
w.close()
|
w.close()
|
||||||
|
|
||||||
describe 'BrowserWindow.capturePage(rect, callback)', ->
|
describe 'BrowserWindow.capturePage(rect, callback)', ->
|
||||||
it 'calls the callback with a Buffer', ->
|
it 'calls the callback with a Buffer', (done) ->
|
||||||
w = new BrowserWindow(show: false)
|
w = new BrowserWindow(show: false)
|
||||||
w.capturePage {x: 0, y: 0, width: 100, height: 100}, (image) ->
|
w.capturePage {x: 0, y: 0, width: 100, height: 100}, (image) ->
|
||||||
assert.equal image.constructor.name, 'SlowBuffer'
|
assert.equal image.constructor.name, 'Buffer'
|
||||||
|
done()
|
||||||
w.close()
|
w.close()
|
||||||
|
|
||||||
describe 'beforeunload handler', ->
|
describe 'beforeunload handler', ->
|
||||||
|
|
Loading…
Reference in a new issue