Closed b2p-fred closed 2 years ago
Just to be clear; the ExportAnswersCommand
is your own code, right?
Yes. Sorry I should have been more precise about this. ExportanswersCommand
is a function in my source code.
No problem, so then to me this looks like that class itself extends from Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand
which can't be auto-loaded. Is this class available in your project? I don't know why phpcov needs it anyway, nor why this code is even loaded, because phpcov is supposed to just merge .cov files.
I do agree with you ... I do not understand why phpcov tries to load some PHP files.
Indeed, my project is based on the Symfony framework and all these classes are involved in the project. Anyway, I do not know how to make phpcov autoload my project included files.
I'd expect phpcov
itself to load vendor/autoload.php
(or it couldn't even find its own classes, right?), but you can explicitly include it like so: php -dauto_prepend_file=vendor/autoload.php vendor/bin/phpcov ...
.
I will make a full new test of all this stuff starting from scratch. I containerized all my application and I hope it may help understanding what happened. I will keep you informed
I will open another issue to explain my new test and all the results I got. I am closing this one.
I give a try to this package with a recent (e.g. version 5/6) Symfony application and I collected a bunch of
.cov
files. I tried to compile all these files with the most recent (e.g. 8.2) version ofphpcov
without any success:This is how I used the live code coverage:
Any thoughts about this ? Many thanks in advance.
PS: I googled for a while to find more information about the
phpcov
merge feature and such a problem but I got no success... perhaps you already encountered the same problem in one of your project :wink: