Skip to content

Commit

Permalink
Merge branch 'master' into fix_20002
Browse files Browse the repository at this point in the history
  • Loading branch information
samdark authored May 16, 2024
2 parents 90b60c1 + 8861f7b commit 7346a46
Show file tree
Hide file tree
Showing 791 changed files with 3,465 additions and 3,868 deletions.
4 changes: 2 additions & 2 deletions .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ clone_folder: C:\projects\yii2

environment:
matrix:
- php_ver: 7.2.4
- php_ver: 7.3.0

cache:
- '%APPDATA%\Composer'
Expand All @@ -30,7 +30,7 @@ install:
- echo extension=php_mbstring.dll >> php.ini
- echo extension=php_openssl.dll >> php.ini
- echo extension=php_pdo_sqlite.dll >> php.ini
- IF NOT EXIST C:\tools\composer.phar (cd C:\tools && appveyor DownloadFile https://getcomposer.org/download/1.4.1/composer.phar)
- IF NOT EXIST C:\tools\composer.phar (cd C:\tools && appveyor DownloadFile https://getcomposer.org/download/2.6.3/composer.phar)

before_test:
- cd C:\projects\yii2
Expand Down
60 changes: 18 additions & 42 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,62 +13,37 @@ concurrency:

jobs:
phpunit:
name: PHP ${{ matrix.php }} on ${{ matrix.os }}
name: PHP ${{ matrix.php }}

runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
include:
- php: 5.4
coverage: none
extensions: apc, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
- php: 5.5
coverage: none
extensions: apc, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
- php: 5.6
coverage: none
extensions: apc, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
- php: 7.0
coverage: none
extensions: apc, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
- php: 7.1
coverage: none
extensions: apc, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
- php: 7.2
coverage: none
extensions: apc, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
- php: 7.3
coverage: none
extensions: apc, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
coverage: none
- php: 7.4
coverage: xdebug
extensions: apc, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
coverage: xdebug
- php: 8.0
coverage: none
extensions: apcu, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
- php: 8.1
coverage: none
- php: 8.1
extensions: apcu, curl, dom, imagick, intl, mbstring, mcrypt, memcached
os: ubuntu-latest
coverage: none
- php: 8.2
extensions: apcu, curl, dom, imagick, intl, mbstring, mcrypt, memcached
coverage: none
os: ubuntu-latest
- php: 8.3
extensions: apcu, curl, dom, imagick, intl, mbstring, mcrypt, memcached
coverage: none
os: ubuntu-latest
- php: 8.4
extensions: apcu, curl, dom, imagick, intl, mbstring, mcrypt, memcached
coverage: none
os: ubuntu-latest

steps:
- name: Generate french locale.
Expand All @@ -90,20 +65,21 @@ jobs:
uses: niden/actions-memcached@v7

- name: Install dependencies.
if: matrix.php != '8.4'
run: composer update $DEFAULT_COMPOSER_FLAGS

- name: Run tests with PHPUnit.
if: matrix.php < '7.4' || matrix.php >= '8.1'
run: vendor/bin/phpunit --verbose --exclude-group $PHPUNIT_EXCLUDE_GROUP --colors=always

- name: Run tests with PHPUnit.
if: matrix.php == '8.0'
run: vendor/bin/phpunit --verbose --exclude-group $PHPUNIT_EXCLUDE_GROUP --colors=always
- name: Install dependencies with PHP 8.4.
if: matrix.php == '8.4'
run: composer update $DEFAULT_COMPOSER_FLAGS --ignore-platform-reqs

- name: Run tests with PHPUnit and generate coverage.
if: matrix.php == '7.4'
run: vendor/bin/phpunit --verbose --exclude-group $PHPUNIT_EXCLUDE_GROUP --coverage-clover=coverage.xml --colors=always

- name: Run tests with PHPUnit.
if: matrix.php != '7.4'
run: vendor/bin/phpunit --verbose --exclude-group $PHPUNIT_EXCLUDE_GROUP --colors=always

- name: Upload coverage to Codecov.
if: matrix.php == '7.4'
uses: codecov/codecov-action@v3
Expand Down
13 changes: 8 additions & 5 deletions .github/workflows/ci-mssql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
include:
- php: 7.4
Expand All @@ -31,6 +32,8 @@ jobs:
mssql: server:2022-latest
- php: 8.3
mssql: server:2022-latest
- php: 8.4
mssql: server:2022-latest

services:
mssql:
Expand Down Expand Up @@ -63,16 +66,16 @@ jobs:
run: composer self-update

- name: Install dependencies with composer
if: matrix.php != '8.4'
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi

- name: Install dependencies with PHP 8.4.
if: matrix.php == '8.4'
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ignore-platform-reqs --ansi

- name: Run MSSQL tests with PHPUnit and generate coverage.
if: matrix.php == '7.4'
run: vendor/bin/phpunit --group mssql --coverage-clover=coverage.xml --colors=always

- name: Run MSSQL tests with PHPUnit.
if: matrix.php > '7.4'
run: vendor/bin/phpunit --group mssql --colors=always

- name: Upload coverage to Codecov.
if: matrix.php == '7.4'
uses: codecov/codecov-action@v3
Expand Down
31 changes: 11 additions & 20 deletions .github/workflows/ci-mysql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,23 +15,14 @@ jobs:
extensions: curl, intl, pdo, pdo_mysql
XDEBUG_MODE: coverage, develop

runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest

php:
- 7.4
- 8.0
- 8.1
- 8.2
- 8.3

mysql:
- 5.7
- latest
os: [ubuntu-latest]
php: [7.4, 8.0, 8.1, 8.2, 8.3, 8.4]
mysql: [5.7, latest]

services:
mysql:
Expand All @@ -56,17 +47,17 @@ jobs:
php-version: ${{ matrix.php }}
tools: composer:v2, pecl

- name: Install dependencies with composer.
- name: Install dependencies with composer
if: matrix.php != '8.4'
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi

- name: Install dependencies with PHP 8.4.
if: matrix.php == '8.4'
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ignore-platform-reqs --ansi

- name: Run MySQL tests with PHPUnit and generate coverage.
if: matrix.php == '7.4'
run: vendor/bin/phpunit --group mysql --coverage-clover=coverage.xml --colors=always

- name: Run MySQL tests with PHPUnit.
if: matrix.php > '7.4'
run: vendor/bin/phpunit --group mysql --colors=always

- name: Upload coverage to Codecov.
if: matrix.php == '7.4'
uses: codecov/codecov-action@v3
Expand Down
7 changes: 2 additions & 5 deletions .github/workflows/ci-oracle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,8 @@ jobs:

strategy:
matrix:
os:
- ubuntu-latest

php:
- 7.4
os: [ubuntu-latest]
php: [7.4]

services:
oci:
Expand Down
35 changes: 11 additions & 24 deletions .github/workflows/ci-pgsql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,14 @@ jobs:
extensions: curl, intl, pdo, pdo_pgsql
XDEBUG_MODE: coverage, develop

runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest

php:
- 7.4
- 8.0
- 8.1
- 8.2
- 8.3

pgsql:
- 10
- 11
- 12
- 13
- 14
- 15
os: [ubuntu-latest]
php: [7.4, 8.0, 8.1, 8.2, 8.3, 8.4]
pgsql: [10, 11, 12, 13, 14, 15]

services:
postgres:
Expand Down Expand Up @@ -64,17 +51,17 @@ jobs:
- name: Update composer.
run: composer self-update

- name: Install dependencies with composer.
- name: Install dependencies with composer
if: matrix.php != '8.4'
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi

- name: Install dependencies with PHP 8.4.
if: matrix.php == '8.4'
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ignore-platform-reqs --ansi

- name: Run Pgsql tests with PHPUnit and generate coverage.
if: matrix.php == '7.4'
run: vendor/bin/phpunit --group pgsql --coverage-clover=coverage.xml --colors=always

- name: Run Pgsql tests with PHPUnit.
if: matrix.php > '7.4'
run: vendor/bin/phpunit --group pgsql --colors=always

- name: Upload coverage to Codecov.
if: matrix.php == '7.4'
uses: codecov/codecov-action@v3
Expand Down
24 changes: 9 additions & 15 deletions .github/workflows/ci-sqlite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,10 @@ jobs:
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest

php:
- 7.4
- 8.0
- 8.1
- 8.2
- 8.3
os: [ubuntu-latest]
php: [7.4, 8.0, 8.1, 8.2, 8.3, 8.4]

steps:
- name: Checkout.
Expand All @@ -46,17 +40,17 @@ jobs:
- name: Update composer.
run: composer self-update

- name: Install dependencies with composer.
- name: Install dependencies with composer
if: matrix.php != '8.4'
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi

- name: Install dependencies with PHP 8.4.
if: matrix.php == '8.4'
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ignore-platform-reqs --ansi

- name: Run SQLite tests with PHPUnit and generate coverage.
if: matrix.php == '7.4'
run: vendor/bin/phpunit --group sqlite --coverage-clover=coverage.xml --colors=always

- name: Run SQLite tests with PHPUnit.
if: matrix.php > '7.4'
run: vendor/bin/phpunit --group sqlite --colors=always

- name: Upload coverage to Codecov.
if: matrix.php == '7.4'
uses: codecov/codecov-action@v3
Expand Down
22 changes: 22 additions & 0 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: lint

on: [push, pull_request]

jobs:
phpcs:
runs-on: ubuntu-latest
name: PHP_CodeSniffer
steps:
- uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
tools: cs2pr

- name: Install dependencies
run: composer install --prefer-dist

- name: Run phpcs
run: vendor/bin/phpcs -q --report=checkstyle framework/ | cs2pr
27 changes: 0 additions & 27 deletions .php_cs

This file was deleted.

2 changes: 1 addition & 1 deletion .scrutinizer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ build:

environment:
php:
version: 7.4.28
version: 8.1
ini:
xdebug.mode: coverage,develop
memory_limit: -1
Expand Down
Loading

0 comments on commit 7346a46

Please sign in to comment.