From 48195741a06e8bb6db38f73de4104965c9a642a8 Mon Sep 17 00:00:00 2001 From: peter279k Date: Wed, 29 Jul 2020 01:33:11 +0800 Subject: [PATCH] Test enhancement for fix PSR-4 autoloading --- .travis.yml | 3 ++- composer.json | 3 --- phpstan.neon | 5 +++++ src/{CombinationGenerator.php => CombinationsGenerator.php} | 0 4 files changed, 7 insertions(+), 4 deletions(-) create mode 100644 phpstan.neon rename src/{CombinationGenerator.php => CombinationsGenerator.php} (100%) diff --git a/.travis.yml b/.travis.yml index 569027d..46ca0bc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,6 +4,7 @@ php: - '7.1' - '7.2' - '7.3' + - '7.4' before_script: - curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter @@ -16,7 +17,7 @@ script: # Fail the Travis CI build on the first error. - set -e - mkdir -p build/logs - - php vendor/bin/phpcs --standard=PSR12 src + - php vendor/bin/phpcs --standard=PSR2 src - php vendor/bin/phpcs --standard=PSR1 tests - php vendor/bin/phpstan analyze --level max src - vendor/bin/phpunit --coverage-text --coverage-clover build/logs/clover.xml diff --git a/composer.json b/composer.json index e5b0df4..9800ce4 100644 --- a/composer.json +++ b/composer.json @@ -37,9 +37,6 @@ "autoload-dev": { "psr-4": { "PHPExperts\\Combinatorics\\Tests\\" : "tests/" } }, - "config": { - "classmap-authoritative": true - }, "scripts": { "post-create-project-cmd": [ "php install.php" diff --git a/phpstan.neon b/phpstan.neon new file mode 100644 index 0000000..22bf6eb --- /dev/null +++ b/phpstan.neon @@ -0,0 +1,5 @@ +parameters: + checkMissingIterableValueType: false + paths: + - src/ + - tests/ diff --git a/src/CombinationGenerator.php b/src/CombinationsGenerator.php similarity index 100% rename from src/CombinationGenerator.php rename to src/CombinationsGenerator.php