In php, there are many aop packages that generate proxy classes to replace the original classes in the composer class map. I'm not sure how to properly generate a code coverage report if this is the case. Can someone please tell me?
I tried to load the proxy class path inside phpunit.xml as well. This generates the proxy class report. But it doesn't make any sense.
If you can, please let me know how to generate the code coverage report correctly in this case. Much appreciated.
The code is here.mineadmin
I am sorry for the unclear description earlier. Here is an example: I have a commonController controller. In this controller, I use the Inject annotation provided by the Hyperf framework. When using this annotation, Hyperf generates a commonController.proxy.php file to automatically inject instances annotated with Inject. The generated proxy file is located in runtime/container/proxy directory. The issue I am facing is that when running unit tests for code coverage report, it actually uses commonController.proxy.php instead of commonController.php. This results in code coverage detection for commonController.php not being accurate. This is frustrating because I want the correct coverage report for automation processes to accurately measure the actual coverage.