Commit Graph

2 Commits (a9980ebd4bdceec5da19c489d14ad6e24ceef3bc)

Author SHA1 Message Date
legendecas 7f496fefb6 report: fix missing section javascriptHeap on OOMError
`Environment::GetCurrent` may not available in the context of OOM.
Removes the cyclic `Environment::GetCurrent` and `env->isolate()`
calls to ensure both `isolate` and `env` is present if available.

However, this behavior is not guaranteed. As
`Environment::GetCurrent` didn't allocate new handles in the heap,
when a Context is entered it can still get the valid env pointer.
Removes the unstable assertion of the absence of env in the test.

PR-URL: https://github.com/nodejs/node/pull/44398
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
2022-09-02 14:01:39 +08:00
Joyee Cheung 04c4688da5 test: split report OOM tests
On some machines the report OOM tests can take too long to complete,
resulting in a timeout. This splits the test into several different
smaller tests to reduce the flakiness of it.

PR-URL: https://github.com/nodejs/node/pull/44389
Refs: https://github.com/nodejs/reliability/issues/356
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
2022-08-29 11:39:15 +08:00