From 220d65670651ca58d59c9943ff8e103c5c187dfd Mon Sep 17 00:00:00 2001 From: Bruce Weirdan Date: Fri, 4 Feb 2022 01:08:14 +0200 Subject: [PATCH] Added backward compatibility check --- .github/workflows/bcc.yml | 47 ++++++++++++++++++++++++++++++++++++ vendor-bin/bcc/composer.json | 5 ++++ 2 files changed, 52 insertions(+) create mode 100644 .github/workflows/bcc.yml create mode 100644 vendor-bin/bcc/composer.json diff --git a/.github/workflows/bcc.yml b/.github/workflows/bcc.yml new file mode 100644 index 00000000000..8bc58be9bb3 --- /dev/null +++ b/.github/workflows/bcc.yml @@ -0,0 +1,47 @@ +name: Check backward compatibility + +on: pull_request +jobs: + bcc: + name: Check backward compatibility + runs-on: ubuntu-latest + steps: + - name: Set up PHP + uses: shivammathur/setup-php@v2 + with: + php-version: '8.1' + tools: composer:v2 + coverage: none + + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - name: Get Composer Cache Directories + id: composer-cache + run: | + echo "::set-output name=files_cache::$(composer config cache-files-dir)" + echo "::set-output name=vcs_cache::$(composer config cache-vcs-dir)" + + - name: Cache composer cache + uses: actions/cache@v2 + with: + path: | + ${{ steps.composer-cache.outputs.files_cache }} + ${{ steps.composer-cache.outputs.vcs_cache }} + key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} + restore-keys: | + ${{ runner.os }}-composer- + + - name: Run composer install + run: | + composer install -o + composer bin bcc install + env: + COMPOSER_ROOT_VERSION: dev-master + + - name: Run BCC + run: vendor/bin/roave-backward-compatibility-check --from="origin/$GITHUB_BASE_REF" --format=github-actions + env: + COMPOSER_ROOT_VERSION: dev-master + diff --git a/vendor-bin/bcc/composer.json b/vendor-bin/bcc/composer.json new file mode 100644 index 00000000000..5baf026b60d --- /dev/null +++ b/vendor-bin/bcc/composer.json @@ -0,0 +1,5 @@ +{ + "require": { + "roave/backward-compatibility-check": "^6.1" + } +}