13 lines
431 B
Plaintext
13 lines
431 B
Plaintext
// Test: actor that allocates too much memory is killed
|
|
// Parent starts a child that allocates arrays in a loop.
|
|
// The child should be killed when it exceeds the heap memory limit.
|
|
$start(function(event) {
|
|
if (event.type == 'greet') {
|
|
// child started, wait for it to die from memory abuse
|
|
}
|
|
if (event.type == 'disrupt') {
|
|
log.test("PASS: memory abusing actor killed")
|
|
$stop()
|
|
}
|
|
}, 'tests/hang_actor_memory')
|