php-code-coverage | provides collection , processing , and rendering functionality | Web Framework library

 by   sebastianbergmann PHP Version: 10.1.2 License: BSD-3-Clause

kandi X-RAY | php-code-coverage Summary

kandi X-RAY | php-code-coverage Summary

php-code-coverage is a PHP library typically used in Server, Web Framework applications. php-code-coverage has no bugs, it has no vulnerabilities, it has a Permissive License and it has medium support. You can download it from GitHub.

Library that provides collection, processing, and rendering functionality for PHP code coverage information.

            kandi-support Support

              php-code-coverage has a medium active ecosystem.
              It has 8600 star(s) with 369 fork(s). There are 56 watchers for this library.
              It had no major release in the last 6 months.
              There are 20 open issues and 569 have been closed. On average issues are closed in 80 days. There are 3 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of php-code-coverage is 10.1.2

            kandi-Quality Quality

              php-code-coverage has 0 bugs and 0 code smells.

            kandi-Security Security

              php-code-coverage has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              php-code-coverage code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              php-code-coverage is licensed under the BSD-3-Clause License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              php-code-coverage releases are not available. You will need to build from source code and install.
              Installation instructions, examples and code snippets are available.
              php-code-coverage saves you 3053 person hours of effort in developing the same functionality from scratch.
              It has 6645 lines of code, 431 functions and 75 files.
              It has high code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi has reviewed php-code-coverage and discovered the below as its top functions. This is intended to give you an instant insight into php-code-coverage implemented functionality, and help decide if they suit your requirements.
            • Process code coverage .
            • Get coverage distribution .
            • Render the item .
            • Get executable lines in a file .
            • Get driver for line coverage .
            • Warm cache analysis .
            • Ensures the Xdebug code feature is enabled .
            • Get build information .
            • Returns the source node .
            • Detect executed lines .
            Get all kandi verified functions for this library.

            php-code-coverage Key Features

            No Key Features are available at this moment for php-code-coverage.

            php-code-coverage Examples and Code Snippets

            No Code Snippets are available at this moment for php-code-coverage.

            Community Discussions


            PHPUnit can't generate code coverage when running tests in separate processes
            Asked 2022-Jan-21 at 17:05

            I have a problem that I could not find the solution on Google. When I run my unit tests with PHPUnit and Xdebug, I would like to do a code coverage.

            However, when I do that, I get this error:



            Answered 2021-Jul-27 at 11:37

            This is likely because with runTestsInSeparateProcesses, PHPUnit starts a new PHP process for every test. And it seems that it does that without Xdebug loaded.

            The PHP that is started for each test needs to be the same as the one that you originally started PHPUnit with. Perhaps there is a different PHP binary first in the PATH?

            If that is the case, the way to solve it is to make sure the "right" PHP is first in the PATH.



            Xdebug 2 vs Xdebug 3 - differences in code coverage
            Asked 2021-Jan-11 at 16:19

            I upgraded Xdebug version from 2.9.3 to 3.0.1 and I found some differences in code coverage results after run unit tests with --code-coverage. Let's say, there are two environments:

            • Environment 1: PHP 7.3.16, Xdebug 2.9.3, php-code-coverage 8.0.2, PHPUnit 9.0.2
            • Environment 2: PHP 7.3.25, Xdebug 3.0.1, php-code-coverage 8.0.2, PHPUnit 9.0.2

            Code example 1:



            Answered 2021-Jan-11 at 16:19

            It is possible that some lines are no longer covered with Xdebug 3 due to it being much more selective on which information is gathered.

            I believe your first issue is fixed in Xdebug 3.0.2 (#1922). For the second issue, if it still persists after upgrading to Xdebug 3.0.2, please file a bug report at following the instructions at — for Code Coverage bugs I would generally only need a fully parsable PHP file that exhibits the problem. StackOverflow is not the place for reporting bugs.



            Composer 2.0.8 issue package-versions-deprecated
            Asked 2020-Dec-17 at 14:30

            Using php 7.2



            Answered 2020-Dec-17 at 14:30

            This seems to be a problem with the virtual box filesystem. I created an issue to composer and hopefully more insight will be gained.




            xdebug : Fatal error with phpunit for code coverage
            Asked 2020-Nov-20 at 10:08

            I wanna to test my code and coverage. I already install Xdebug extension and when I verify with php -v command, all i'ts good like that :



            Answered 2020-Nov-20 at 10:08

            I already add xdebug.coverage_enable = On in my php.ini file so I don't understand why the system say that :/

            Xdebug v3.0.0RC1
            PHPUnit 7.5.20

            Either upgrade PHPUnit to the version that knows about Xdebug 3 ... or downgrade Xdebug to 2.x (2.9.8 is the latest).

            Thing is: xdebug.coverage_enable is the Xdebug 2 option. That option does nothing in Xdebug 3 where you should use xdebug.mode = coverage instead.

            Xdebug 3 uses different config options than v2 and your version of PHPUnit is simply not aware of that. Xdebug 3 will simply report an empty value/0 for no-longer-used Xdebug 2 options.


            P.S. You should see a warning when you run php -i with Xdebug 3 -- it should complain if such a wrong/outdated option is present in your php.ini (unless you have configured PHP to not to report any startup errors I guess).

            In either case: run php -i and see the actual live values from Xdebug section: what value that option has.



            Laravel installation and create-project issue
            Asked 2020-Sep-15 at 16:55

            I was facing an issue to install laravel in my ubuntu. Please help me.



            Answered 2020-Sep-15 at 16:55

            I used this and It works for me.



            Error while trying to deploy Laravel to Cloud Foundry
            Asked 2020-Jul-31 at 14:08

            I'm trying to deploy a basic Laravel application to Cloud Foundry. Below you can see the output after I ran ibmcloud cf push:



            Answered 2020-Jul-31 at 14:08

            The solution to this issue was renaming the .pb-config folder to .bp-config. The tutorial available under this link has a spelling error and that was the reason for all the suffering...



            php artisan command not working in ubuntu
            Asked 2020-Jul-07 at 11:36

            When i do php artisan or php artisan serve in my laravel project it shows some error and I don't know how to solve it. I tried removing composer and again installing it also doing composer update but it does not seem to solve the problem. Operationg System: Ubuntu 20.04 LTS

            My Error:



            Answered 2020-Jul-07 at 11:36

            Did you installed all the necessary vendor packages locally? Does your "vendor" directory exists?

            Don't forget to use:



            dockerfile: `composer install --no-dev installs dev-dependencies, then deletes them straight away after
            Asked 2020-Jun-16 at 06:55

            My docker-compose setup does (I think) some wierd things.

            I am installing from this composer.json:



            Answered 2020-Jun-16 at 06:55

            Pretty simple: you run composer update (which will update the list of packages, and install them), and afterwards you run composer install --no-dev.

            Just out of curiosity: this is only done when updating the Docker image. Is there any good reason for this? Why don't you decouple the image and the source code running in that image?



            Composer install fail Digitalocean web hosting
            Asked 2020-Apr-02 at 06:01

            What I did:

            1. SSH Setuped
            2. Php7.2 installed
            3. apache2 installed
            4. Pull Files from GitLab

            When I run this apt install Composer



            Answered 2020-Apr-02 at 06:01

            install the following php extensions -

            php7.2-mbstring php7.2-dom

            Run the following command to install them -



            Why is Composer Install Failing All of the Sudden?
            Asked 2020-Mar-25 at 08:02

            I'm running composer install in my local env and in production env and they are both failing. This just started today. I've reviewed the code changes and the composer files haven't changed. Can anyone shed some light on this...i have no idea what it could be. I thought github was down or something but I do get some packages installed successfully. I'm getting errors like this:


            • Installing phpunit/php-timer (2.1.2): Downloading (100%)
            • Installing phpunit/php-text-template (1.2.1): Downloading (100%)
            • Installing phpunit/php-file-iterator (2.0.2): Downloading (0%) Failed to download phpunit/php-file-iterator from dist: Could not authenticate against Now trying to download from source
            • Installing phpunit/php-file-iterator (2.0.2): Cloning 050bedf145 from cache
            • Installing theseer/tokenizer (1.1.3): Downloading (0%) Failed to download theseer/tokenizer from dist: Could not authenticate against Now trying to download from source
            • Installing theseer/tokenizer (1.1.3): Cloning 11336f6f84 from cache
            • Installing sebastian/code-unit-reverse-lookup (1.0.1): Downloading (0%) Failed to download sebastian/code-unit-reverse-lookup from dist: Could not authenticate against Now trying to download from source
            • Installing sebastian/code-unit-reverse-lookup (1.0.1): Cloning 4419fcdb5e from cache
            • Installing phpunit/php-code-coverage (6.1.4): Downloading (0%) Failed to download phpunit/php-code-coverage from dist: Could not authenticate against Now trying to download from source
            • Installing phpunit/php-code-coverage (6.1.4): Cloning 807e6013b0 from cache
            • Installing doctrine/instantiator (1.3.0): Downloading (0%) Failed to download doctrine/instantiator from dist: Could not authenticate against Now trying to download from source
            • Installing doctrine/instantiator (1.3.0): Cloning ae466f7262 from cache
            • Installing phpspec/prophecy (v1.10.2): Downloading (0%) Failed to download phpspec/prophecy from dist: Could not authenticate against Now trying to download from source
            • Installing phpspec/prophecy (v1.10.2): Cloning b4400efc9d from cache
            • Installing phar-io/version (2.0.1): Downloading (0%) Failed to download phar-io/version from dist: Could not authenticate against Now trying to download from source
            • Installing phar-io/version (2.0.1): Cloning 45a2ec53a7 from cache
            • Installing phar-io/manifest (1.0.3): Downloading (0%) Failed to download phar-io/manifest from dist: Could not authenticate against Now trying to download from source
            • Installing phar-io/manifest (1.0.3): Cloning 7761fcacf0 from cache
            • Installing myclabs/deep-copy (1.9.5): Downloading (0%) Failed to download myclabs/deep-copy from dist: Could not authenticate against Now trying to download from source
            • Installing myclabs/deep-copy (1.9.5): Cloning b2c28789e8 from cache
            • Installing phpunit/phpunit (7.5.20): Downloading (0%) Failed to download phpunit/phpunit from dist: Could not authenticate against Now trying to download from source
            • Installing phpunit/phpunit (7.5.20): Cloning 9467db479d

            The process "git clone --no-checkout '' '/var/www/vendor/phpunit/phpunit' && cd '/var/www/vendor/phpunit/phpunit' && git remote add composer '' && git fetch composer && git remote set-url origin '' && git remote set-url composer ''" exceeded the timeout of 300 seconds. > install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--no-custom-installers] [--no-autoloader] [--no-scripts] [--no-progress] [--no-suggest] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--ignore-platform-reqs] [--] []...

            ERROR: Service 'contianer_name' failed to build: The command '/bin/sh -c composer install && rm $(which composer)' returned a non-zero code: 1



            Answered 2020-Mar-25 at 08:02

            We've been seeing the same, and suspect its either a change in Composer behaviour since 1.10, or changes to rate limits on the GitHub side.

            It looks like it first attempts HTTP downloads (it really doesn't help that Composer doesn't show the exact HTTP error), and then falls back to cloning source. The latter works for a while, but then also results in timeouts, possibly because GitHub is limiting these as well.

            Either way, what fixed it for us is making sure Composer HTTP requests to GitHub are authenticated. See the docs here:

            1. Create an OAuth token on GitHub. Read more on this.

            2. Add it to the configuration running composer config -g


            Community Discussions, Code Snippets contain sources that include Stack Exchange Network


            No vulnerabilities reported

            Install php-code-coverage

            You can add this library as a local, per-project dependency to your project using Composer:.


            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
          • HTTPS


          • CLI

            gh repo clone sebastianbergmann/php-code-coverage

          • sshUrl


          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular Web Framework Libraries


            by angular


            by pallets


            by gin-gonic


            by php


            by symfony

            Try Top Libraries by sebastianbergmann


            by sebastianbergmannPHP


            by sebastianbergmannPHP


            by sebastianbergmannPHP


            by sebastianbergmannPHP


            by sebastianbergmannPHP