I am running jestjs unit tests with several ten/hundred thousands of data (pass in as array to test.each()), and it hits heap out of memory.
google online and have try: NODE_OPTIONS='--max-old-space-size=8192' jest --detectOpenHandles --logHeapUsage
but the test like stuck at 1 test suite for overnight, checking at os level, memory 100%, disk 100%, but CPU 4% only. I am guessing it was not enough memory and pause??
The program unit being test is pretty simple, create an object , do some calculation and return result. so I guess, the memory use for previous tests didn't get free up?
thank you very much!