PHP code example of satooshi / php-coveralls

1. Go to this page and download the library: Download satooshi/php-coveralls library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

satooshi / php-coveralls example snippets




https://github.com/php-coveralls/php-coveralls/releases/download/v2.7.0/php-coveralls.phar
sh
$ wget https://github.com/php-coveralls/php-coveralls/releases/download/v2.7.0/php-coveralls.phar
$ chmod +x php-coveralls.phar
sh
$ composer 
sh
$ composer 
sh
# HTTP
$ git clone https://github.com/php-coveralls/php-coveralls.git
# SSH
$ git clone [email protected]:php-coveralls/php-coveralls.git
json
    ""php-coveralls/php-coveralls": "^2.7",
        "phpunit/phpcov": "^2.0"
    },
sh
# get information
php vendor/bin/phpcov.php --help

# merge coverage.cov logs under build/cov
php vendor/bin/phpcov.php merge --clover build/logs/clover.xml build/cov

# in case of memory exhausting error
php -d memory_limit=-1 vendor/bin/phpcov.php ...
sh
curl -s http://getcomposer.org/installer | php
php composer.phar install --dev --no-interaction
mkdir -p build/logs
sh
php vendor/bin/phpunit -c phpunit.xml.dist
php vendor/bin/php-coveralls
yaml
- name: Upload coverage results to Coveralls
  env:
    COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
  run: |
    composer global 
sh
COVERALLS_FLAG_NAME=$YOUR_PHP_VERSION
sh
php vendor/bin/php-coveralls --help