Skip to content

Commit

Permalink
test: make test-memory-usage predictable
Browse files Browse the repository at this point in the history
The current test relies on undeterministic behavior from V8 GC, and on
newer versions of V8 this test ocasionally fails because that behavior
changed.  Prevent that from happening using --predictable-gc-schedule.
If this test fails in the future, it should fail consistently instead of
ocasionally, which should help debug.

Ref: nodejs/node-v8#144 (comment)
Signed-off-by: Matheus Marchini <mmarchini@netflix.com>
  • Loading branch information
mmarchini committed Mar 12, 2020
1 parent f8f2089 commit 5807d3a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/parallel/test-memory-usage.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.

// Flags: --no-concurrent-array-buffer-freeing
// Flags: --predictable-gc-schedule
'use strict';
const common = require('../common');
const assert = require('assert');
Expand Down

0 comments on commit 5807d3a

Please sign in to comment.