Skip to content
Permalink
Browse files

Ensure BC of API, compat with `roave/you-are-using-it-wrong`, complet…

…eness of `composer.json` (#2140)

* Test against `roave/you-are-using-it-wrong`

* Added CI step to ensure BC of declared API

* Added step to ensure `composer.json` has all used deps

* Including CI check tools as dev dependencies

* Typo fix: s/backwards/backward

* Run `roave/backward-compatibility-check` off an isolated location with no other dependencies

* Run `test-with-real-projects` task with PHP 7.4 as base runtime

* Run `testing-with-real-projects` also against `ocramius/proxy-manager`

`ocramius/proxy-manager` is an extremely heavy `vimeo/psalm` consumer,
and relies on a lot of the templated types system to generate real
types for proxies produced by runtime evaluation.
  • Loading branch information
Ocramius authored and muglug committed Jan 1, 2020
1 parent 270a99f commit b26c57237f7f0f7def838193402318eb49e39022
Showing with 33 additions and 1 deletion.
  1. +4 −1 .circleci/config.yml
  2. +14 −0 .travis.yml
  3. +15 −0 bin/test-with-real-projects.sh
@@ -4,6 +4,9 @@ executors:
php-72:
docker:
- image: thecodingmachine/php:7.2-v2-cli
php-74:
docker:
- image: thecodingmachine/php:7.4-v3-cli
jobs:
install-and-self-analyse:
executor: php-72
@@ -90,7 +93,7 @@ jobs:
paths:
- build/psalm.phar
test-with-real-projects:
executor: php-72
executor: php-74
steps:
- checkout # used here just for the side effect of loading the github public ssh key so we can clone other stuff
- attach_workspace:
@@ -62,6 +62,20 @@ jobs:
script:
- vendor/bin/phpcs

- stage: Ensure API BC
php: 7.4
env: DEPS="high"
script:
- mkdir /tmp/bc-check && composer require --working-dir=/tmp/bc-check --dev roave/backward-compatibility-check:^4.0.0
- /tmp/bc-check/vendor/bin/roave-backward-compatibility-check

- stage: Ensure no transient used dependencies
php: 7.3
env: DEPS="high"
script:
- composer require --dev maglnet/composer-require-checker:^2.0.0
- ./vendor/bin/composer-require-checker check ./composer.json

- stage: Phar build
php: 7.3
env: DEPS="high"
@@ -20,3 +20,18 @@ git clone git@github.com:muglug/collections.git
cd collections
composer install
~/project/psalm --monochrome --show-info=false

cd /tmp/testing-with-real-projects

git clone git@github.com:Ocramius/ProxyManager.git
cd ProxyManager
composer install
~/project/build/psalm.phar --monochrome

cd /tmp/testing-with-real-projects

git clone git@github.com:roave/you-are-using-it-wrong.git
cd you-are-using-it-wrong
composer install
~/project/build/psalm.phar --monochrome
./vendor/bin/phpunit

0 comments on commit b26c572

Please sign in to comment.
You can’t perform that action at this time.