Skip to content

Commit

Permalink
Merge branch 'master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
samdark authored Mar 27, 2024
2 parents 7cf3c65 + 923c309 commit 848ddf9
Show file tree
Hide file tree
Showing 220 changed files with 1,989 additions and 1,541 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
53 changes: 10 additions & 43 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,58 +13,29 @@ 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
Expand Down Expand Up @@ -96,18 +67,14 @@ jobs:
- name: Install dependencies.
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: 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
6 changes: 1 addition & 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 Down Expand Up @@ -68,13 +69,8 @@ jobs:
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --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
8 changes: 2 additions & 6 deletions .github/workflows/ci-mysql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@ 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, 8.4]
Expand Down Expand Up @@ -50,13 +51,8 @@ jobs:
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --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
8 changes: 2 additions & 6 deletions .github/workflows/ci-pgsql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@ 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, 8.4]
Expand Down Expand Up @@ -54,13 +55,8 @@ jobs:
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --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
6 changes: 1 addition & 5 deletions .github/workflows/ci-sqlite.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:
os: [ubuntu-latest]
php: [7.4, 8.0, 8.1, 8.2, 8.3, 8.4]
Expand All @@ -43,13 +44,8 @@ jobs:
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --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
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
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ The framework is easy to adjust to meet your needs, because Yii has been designe
[![Latest Stable Version](https://img.shields.io/packagist/v/yiisoft/yii2.svg)](https://packagist.org/packages/yiisoft/yii2)
[![Total Downloads](https://img.shields.io/packagist/dt/yiisoft/yii2.svg)](https://packagist.org/packages/yiisoft/yii2)
[![Build Status](https://github.com/yiisoft/yii2/workflows/build/badge.svg)](https://github.com/yiisoft/yii2/actions)
[![Code Coverage](https://scrutinizer-ci.com/g/yiisoft/yii2/badges/coverage.png?s=31d80f1036099e9d6a3e4d7738f6b000b3c3d10e)](https://scrutinizer-ci.com/g/yiisoft/yii2/)
[![codecov](https://codecov.io/gh/yiisoft/yii2/graph/badge.svg?token=Exm6sRwhJ6)](https://codecov.io/gh/yiisoft/yii2)
[![Scrutinizer Quality Score](https://scrutinizer-ci.com/g/yiisoft/yii2/badges/quality-score.png?s=b1074a1ff6d0b214d54fa5ab7abbb90fc092471d)](https://scrutinizer-ci.com/g/yiisoft/yii2/)

Installation
------------

- The minimum required PHP version of Yii is PHP 5.4.
- The minimum required PHP version of Yii is PHP 7.3.
- It works best with PHP 8.
- [Follow the Definitive Guide](https://www.yiiframework.com/doc-2.0/guide-start-installation.html)
in order to get step by step instructions.
Expand Down
21 changes: 3 additions & 18 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
"yiisoft/yii2": "self.version"
},
"require": {
"php": ">=5.4.0",
"php": ">=7.3.0",
"ext-mbstring": "*",
"ext-ctype": "*",
"lib-pcre": "*",
Expand All @@ -82,11 +82,10 @@
"paragonie/random_compat": ">=1"
},
"require-dev": {
"cweagans/composer-patches": "^1.7",
"phpunit/phpunit": "4.8.34",
"cebe/indent": "~1.0.2",
"johnkary/phpunit-speedtrap": "^1.0",
"dealerdirect/phpcodesniffer-composer-installer": "*",
"dms/phpunit-arraysubset-asserts": "^0.5",
"phpunit/phpunit": "^9.6",
"yiisoft/yii2-coding-standards": "^3.0"
},
"repositories": [
Expand Down Expand Up @@ -122,20 +121,6 @@
"extra": {
"branch-alias": {
"dev-master": "2.0.x-dev"
},
"composer-exit-on-patch-failure": true,
"patches": {
"phpunit/phpunit-mock-objects": {
"Fix PHP 7 and 8 compatibility": "https://yiisoft.github.io/phpunit-patches/phpunit_mock_objects.patch"
},
"phpunit/php-file-iterator": {
"Fix PHP 8.1 compatibility": "https://yiisoft.github.io/phpunit-patches/phpunit_path_file_iterator.patch"
},
"phpunit/phpunit": {
"Fix PHP 7 compatibility": "https://yiisoft.github.io/phpunit-patches/phpunit_php7.patch",
"Fix PHP 8 compatibility": "https://yiisoft.github.io/phpunit-patches/phpunit_php8.patch",
"Fix PHP 8.1 compatibility": "https://yiisoft.github.io/phpunit-patches/phpunit_php81.patch"
}
}
}
}
Loading

0 comments on commit 848ddf9

Please sign in to comment.