<commit_before>language: php
php: [ 7.1, 7.2, nightly ]
sudo: false

env:

matrix:
  fast_finish: true
  allow_failures:
    - php: nightly

install:
  - travis_retry composer install --no-interaction --prefer-dist --optimize-autoloader
  - travis_retry wget https://phar.io/releases/phive.phar
  - travis_retry php phive.phar --no-progress install --trust-gpg-keys 4AA394086372C20A phpunit
  - echo "tests won't work from phpunit.phar, because some of this package's deps are in that phar..."
  - travis_retry composer require --dev phpunit/phpunit

script:
  - ./vendor/bin/phpunit --no-coverage

jobs:
  include:
    - stage: coverage
      php: 7.1
      before_script:
        - echo "code coverage won't work from phpunit.phar, because some of this package's deps are in that phar..."
        - travis_retry composer require --dev phpunit/phpunit
      script:
        - ./vendor/bin/phpunit
      after_script:
        - travis_retry php phive.phar --no-progress install --trust-gpg-keys E82B2FB314E9906E php-coveralls/php-coveralls && ./tools/php-coveralls --verbose
        - travis_retry wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml

    - stage: lint
      php: 7.1
      before_script:
        - travis_retry php phive.phar --no-progress install --trust-gpg-keys 8E730BA25823D8B5 phpstan
      script:
        - ./tools/phpstan analyse src --level max --configuration phpstan.neon
        - composer create-project symplify/easy-coding-standard temp/ecs && temp/ecs/bin/ecs check src tests

cache:
  directories:
  - $HOME/.composer/cache/files
  - $HOME/.phive

notifications:
  irc: "irc.freenode.org#phpdocumentor"
  slack:
    secure: "<KEY>
  email:
  - <EMAIL>
  - <EMAIL><commit_msg>do not use phpunit.phar against a package whose deps are in that phar<commit_after>language: php
php: [ 7.1, 7.2, nightly ]
sudo: false

env:

matrix:
  fast_finish: true
  allow_failures:
    - php: nightly

install:
  - travis_retry composer install --no-interaction --prefer-dist --optimize-autoloader
  - travis_retry wget https://phar.io/releases/phive.phar
  - travis_retry composer require --dev phpunit/phpunit # cannot trust phpunit.phar, because of reflection-docblock in that phar..."

script:
  - ./vendor/bin/phpunit --no-coverage

jobs:
  include:
    - stage: coverage
      php: 7.1
      script:
        - ./vendor/bin/phpunit
      after_script:
        - travis_retry php phive.phar --no-progress install --trust-gpg-keys E82B2FB314E9906E php-coveralls/php-coveralls && ./tools/php-coveralls --verbose
        - travis_retry wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml

    - stage: lint
      php: 7.1
      before_script:
        - travis_retry php phive.phar --no-progress install --trust-gpg-keys 8E730BA25823D8B5 phpstan
      script:
        - ./tools/phpstan analyse src --level max --configuration phpstan.neon
        - composer create-project symplify/easy-coding-standard temp/ecs && temp/ecs/bin/ecs check src tests

cache:
  directories:
  - $HOME/.composer/cache/files
  - $HOME/.phive

notifications:
  irc: "irc.freenode.org#phpdocumentor"
  slack:
    secure: "<KEY>
  email:
  - <EMAIL>
  - <EMAIL>
{'fraction_non_alphanumeric': 0.11545454545454545, 'fraction_numerical': 0.021212121212121213, 'mean_word_length': 2.7639680729760547, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 4, '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': '852412', 'n_tokens_mistral': 1234, 'n_tokens_neox': 1146, 'n_words': 272}