[ACCOUNT-2732] refactor: replace module-lib-service-container #2295
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Accounts Quality Control PHP | |
on: | |
pull_request: | |
types: [opened, reopened, synchronize, labeled] | |
jobs: | |
php-linter: | |
name: PHP Syntax check 5.6|7.2|7.3 | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: PHP syntax checker 5.6 | |
uses: prestashop/github-action-php-lint/5.6@master | |
with: | |
folder-to-exclude: "! -path \"./tests/*\"" | |
- name: PHP syntax checker 7.2 | |
uses: prestashop/github-action-php-lint/7.2@master | |
with: | |
folder-to-exclude: "! -path \"./tests/*\"" | |
- name: PHP syntax checker 7.3 | |
uses: prestashop/github-action-php-lint/7.3@master | |
with: | |
folder-to-exclude: "! -path \"./tests/*\"" | |
php-cs-fixer: | |
name: PHP-CS-FIXER | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Run PHP-CS-Fixer | |
uses: prestashopcorp/github-action-php-cs-fixer@master | |
phpunit: | |
name: Testsuite for Prestashop ${{ matrix.presta-versions }} | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
presta-versions: | |
- "1.6.1.24-5.6-fpm-stretch" | |
- "1.6.1.24-7.1" | |
- "1.7.8.5-7.4" | |
- "8.1.5-7.4" | |
- "nightly" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Scoped dependencies | |
run: make php-scoper | |
- name: Start container & install module | |
run: | | |
make platform-${{ matrix.presta-versions }} | |
- name: Feature tests | |
run: | | |
make phpunit-run-unit | |
- name: E2e tests | |
run: | | |
make phpunit-run-feature | |
- name: Display logs | |
if: "!success()" | |
run: | | |
make phpunit-display-logs | |
- name: PHPStan | |
if: matrix.presta-versions == '1.6.1.24-7.1' || matrix.presta-versions == '1.7.7.8-7.1' | |
run: | | |
make phpstan | |
- name: header-stamp | |
if: matrix.presta-versions == '1.6.1.24-5.6-fpm-stretch' | |
run: | | |
make header-stamp-test | |
notify-earth: | |
if: ${{ github.event.action == 'labeled' && github.event.label.name == 'ready to review' }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Notify everyone when PR is ready to be reviewed | |
uses: rtCamp/action-slack-notify@v2 | |
env: | |
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | |
SLACK_COLOR: 2986CC | |
SLACK_TITLE: 👀 it's review time! | |
SLACK_MESSAGE: "🥷 ${{ github.event.pull_request.title }}" | |
SLACK_FOOTER: "https://github.com/PrestaShopCorp/ps_accounts/pull/${{ github.event.pull_request.number }}" | |
SLACK_USERNAME: QABot | |
SLACK_CHANNEL: squad-account-dev | |
SLACK_ICON: https://avatars.githubusercontent.com/u/56089550?s=48&v=4 |