<commit_before>language: php
php:
  - 5.6
  - 7.0
  - 7.1
  - nightly
  - hhvm
sudo: false
services:
  - memcached
  - mysql
#  - postgresql
#addons:
#  postgresql: "9.4"
env:
  matrix:
    - DB=MySQLi
    - DB=SQLite
#    - DB=PostgreSQL
matrix:
  allow_failures:
    - php: nightly
# Travis have too old HHVM, can't rely on it yet
    - php: hhvm
#    - env: DB=PostgreSQL
before_script:
  - mysql -e 'CREATE DATABASE `travis`;'
  - |
    if [[ $TRAVIS_PHP_VERSION = '5.6' ]]; then
      echo yes | pecl install apcu-4.0.11
    fi
  - |
    if [[ $TRAVIS_PHP_VERSION = '7.0' ]]; then
      echo yes | pecl install apcu-5.1.5
    fi
  - |
    if [[ $TRAVIS_PHP_VERSION != 'hhvm' ]]; then
      echo "extension = memcached.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
    fi
# Only compute code coverage on PHP 7.0
# HHVM doesn't have write support for Phar archives, so we'll only run quick tests on it
script:
  - |
    if [[ $TRAVIS_PHP_VERSION != '7.0' ]]; then
      export SKIP_COVERAGE=1
    fi
  - |
    if [[ $TRAVIS_PHP_VERSION = 'hhvm' ]]; then
      hhvm phpt-tests-runner tests/quick
    else
      php -d variables_order=EGPCS phpt-tests-runner tests
    fi
after_success:
  - |
    if [[ $TRAVIS_PHP_VERSION = '7.0' && $DB = 'SQLite' ]]; then
      php -d variables_order=EGPCS -d phar.readonly=Off ci/upload_build.php
    fi
after_script:
  - |
    if [[ $TRAVIS_PHP_VERSION = '7.0' ]]; then
      php tests/code_coverage_report.php
      travis_retry wget https://scrutinizer-ci.com/ocular.phar
      php ocular.phar code-coverage:upload --format=php-clover tests/code_coverage_report/clover.xml
    fi
<commit_msg>Limit uploading to SourceForge to 2 minutes timeout in Travis CI (otherwise it fails to upload code coverage to Scrutinizer)<commit_after>language: php
php:
  - 5.6
  - 7.0
  - 7.1
  - nightly
  - hhvm
sudo: false
services:
  - memcached
  - mysql
#  - postgresql
#addons:
#  postgresql: "9.4"
env:
  matrix:
    - DB=MySQLi
    - DB=SQLite
#    - DB=PostgreSQL
matrix:
  allow_failures:
    - php: nightly
# Travis have too old HHVM, can't rely on it yet
    - php: hhvm
#    - env: DB=PostgreSQL
before_script:
  - mysql -e 'CREATE DATABASE `travis`;'
  - |
    if [[ $TRAVIS_PHP_VERSION = '5.6' ]]; then
      echo yes | pecl install apcu-4.0.11
    fi
  - |
    if [[ $TRAVIS_PHP_VERSION = '7.0' ]]; then
      echo yes | pecl install apcu-5.1.5
    fi
  - |
    if [[ $TRAVIS_PHP_VERSION != 'hhvm' ]]; then
      echo "extension = memcached.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
    fi
# Only compute code coverage on PHP 7.0
# HHVM doesn't have write support for Phar archives, so we'll only run quick tests on it
script:
  - |
    if [[ $TRAVIS_PHP_VERSION != '7.0' ]]; then
      export SKIP_COVERAGE=1
    fi
  - |
    if [[ $TRAVIS_PHP_VERSION = 'hhvm' ]]; then
      hhvm phpt-tests-runner tests/quick
    else
      php -d variables_order=EGPCS phpt-tests-runner tests
    fi
after_success:
  - |
    if [[ $TRAVIS_PHP_VERSION = '7.0' && $DB = 'SQLite' ]]; then
      timeout 120 php -d variables_order=EGPCS -d phar.readonly=Off ci/upload_build.php
    fi
after_script:
  - |
    if [[ $TRAVIS_PHP_VERSION = '7.0' ]]; then
      php tests/code_coverage_report.php
      travis_retry wget https://scrutinizer-ci.com/ocular.phar
      php ocular.phar code-coverage:upload --format=php-clover tests/code_coverage_report/clover.xml
    fi

{'fraction_non_alphanumeric': 0.12635273471775374, 'fraction_numerical': 0.01754899093302135, 'mean_word_length': 2.577405857740586, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6043722', 'n_tokens_mistral': 1380, 'n_tokens_neox': 1321, 'n_words': 323}