Increase the JavaStack heap memory for protractor

浪子不回头ぞ 提交于 2019-12-31 03:47:06

问题


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

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!