问题
I am running test cases using protractor, but sometimes I'm facing error
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
How can I increase the Javascript Heap size of protractor?
I read about --max-old-space-size
, buthow this parameter can be set in protractor?
回答1:
If your Nodejs is v8.0.0 or later, you can set it by Environmen Variable: NODE_OPTIONS
For linux:
NODE_OPTIONS="--max-old-space-size=512"
For windows:
More detail look at here
回答2:
set NODE_OPTIONS="--max-old-space-size=4096"
(or)
export NODE_OPTIONS="--max-old-space-size=4096"
来源:https://stackoverflow.com/questions/48561074/increase-the-javastack-heap-memory-for-protractor