feat: add process.getBlinkMemoryInfo() (#17762)

This commit is contained in:
Milan Burda 2019-05-30 11:50:35 +02:00 committed by Alexey Kuzmin
parent 2dbd2c07e4
commit a1226d75ff
6 changed files with 42 additions and 0 deletions

View file

@ -38,6 +38,15 @@ describe('process module', () => {
})
})
describe('process.getBlinkMemoryInfo()', () => {
it('returns blink memory information object', () => {
const heapStats = process.getBlinkMemoryInfo()
expect(heapStats.allocated).to.be.a('number')
expect(heapStats.marked).to.be.a('number')
expect(heapStats.total).to.be.a('number')
})
})
describe('process.getProcessMemoryInfo()', async () => {
it('resolves promise successfully with valid data', async () => {
const memoryInfo = await process.getProcessMemoryInfo()