test: remove non-applicable processMemoryInfo specs (#17679)

This commit is contained in:
Shelley Vohr 2019-04-05 07:53:25 -07:00 committed by GitHub
parent 9c3cb55ef2
commit c4020308c9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 38 deletions

View file

@ -1837,29 +1837,6 @@ describe('BrowserWindow module', () => {
w.loadFile(path.join(fixtures, 'pages', 'window-open.html'))
})
// TODO(alexeykuzmin): `GetProcessMemoryInfo()` is not available starting Ch67.
xit('releases memory after popup is closed', (done) => {
w.destroy()
w = new BrowserWindow({
show: false,
webPreferences: {
preload,
sandbox: true
}
})
w.loadFile(path.join(fixtures, 'api', 'sandbox.html'), { search: 'allocate-memory' })
ipcMain.once('answer', function (event, { bytesBeforeOpen, bytesAfterOpen, bytesAfterClose }) {
const memoryIncreaseByOpen = bytesAfterOpen - bytesBeforeOpen
const memoryDecreaseByClose = bytesAfterOpen - bytesAfterClose
// decreased memory should be less than increased due to factors we
// can't control, but given the amount of memory allocated in the
// fixture, we can reasonably expect decrease to be at least 70% of
// increase
assert(memoryDecreaseByClose > memoryIncreaseByOpen * 0.7)
done()
})
})
// see #9387
it('properly manages remote object references after page reload', (done) => {
w.destroy()