9951 explained code solutions for 126 technologies


phpunitHow to increase memory limit in PHPUnit?


To increase memory limit in PHPUnit, you can use the --testdox-html option. This option allows you to specify the maximum memory limit for the test suite. For example:

phpunit --testdox-html --testdox-html-memory-limit=128M

This will set the memory limit to 128MB.

Code explanation

  • --testdox-html: This option allows you to specify the maximum memory limit for the test suite.
  • --testdox-html-memory-limit: This option specifies the maximum memory limit for the test suite.

Helpful links

Edit this code on GitHub