1

Initially my problem was getting an error whenever I add --coverage-html in phpunit run. It's weird because I don't get any errors whithout coverage. The error didn't have any error messages other than the letter E in the dots that looked liked this:

.....EEEEEEE

logs were not telling me on which test the errors where coming from so i read the phpunit doc to find answers and learned that adding --testdox would output a checklist format. So I added --testdox to my run script. This is what tail of the logs look like:

someTestA
 [x] Some test 1
 [ ] Some test 2
 [ ] Some test 3

someTestB

It literally wasn't spitting out any logs after the line someTestB. I am now on quest to get error messages on my why those tests are failing.

This is my run script:

$ phpunit --configuration phpunit-configs/myconfig.xml --testdox --coverage-html test-reports/html

This is what my phpunit config looks like:

<phpunit
    backupGlobals="false"
    backupStaticAttributes="false"
    bootstrap="../tests/bootstrap.php"
    colors="true"
    convertErrorsToExceptions="false"
    convertNoticesToExceptions="false"
    convertWarningsToExceptions="false"
    processIsolation="false"
    stopOnFailure="false"
    syntaxCheck="false"
    verbose="true"
>

This is what my php ini looks like:

<php>
    <server name="REQUEST_METHOD" value="GET" />
    <server name="REMOTE_ADDR" value="127.0.0.1" />
    <server name="SERVER_SOFTWARE" value="PHP CLI" />
    <ini name="memory_limit" value="2048M" />
    <ini name="error_reporting" value="E_ALL" />
    <ini name="display_errors" value="On" />
    <ini name="display_startup_errors" value="On" />
</php>

1 Answer 1

1

Your version of PHPUnit is outdated. Recent version print detailed information in case a test is not successfully executed when TestDox output is used.

Sign up to request clarification or add additional context in comments.

3 Comments

Where can I tail the logs atleast?. Upgrading phpunit is not option at the moment
After tailing the logs i still am not able to get any information
Do not use --testdox if you do not want TestDox output.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.