4

I want to generate coverhtml for my classes only currently I am using command like,

    phpunit --coverage-html=../../coverage ../../test/assertion.php

but it is testing the code in the vendor folder as well.

1
  • 1
    Use the bootstrap or XML file for options to include/exclude directories. Commented Feb 18, 2014 at 16:25

1 Answer 1

2

Using the XML file, you can include the directories you want to process, and exclude the ones you do not.

<filter>
    <whitelist processUncoveredFilesFromWhitelist="true">
        <directory suffix=".class">.</directory>
        <directory suffix=".fn">.</directory>
        <directory suffix=".php">.</directory>
        <exclude>
            <directory>ExternalLibraries</directory>
        </exclude>
    </whitelist>
</filter>
Sign up to request clarification or add additional context in comments.

Comments

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.