diff --git a/.github/workflows/ci-mssql.yml b/.github/workflows/ci-mssql.yml index bb90b4e..ad39a85 100644 --- a/.github/workflows/ci-mssql.yml +++ b/.github/workflows/ci-mssql.yml @@ -23,6 +23,9 @@ jobs: - php: '8.0' extensions: pdo, pdo_sqlsrv mssql: 'server:2019-latest' + - php: '8.1' + extensions: pdo, pdo_sqlsrv-5.10.0beta2 + mssql: 'server:2019-latest' services: mssql: @@ -62,10 +65,11 @@ jobs: run: composer self-update - name: Install dependencies with composer + if: matrix.php != '8.2' run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi - - name: Install dependencies with composer php 8.0 - if: matrix.php == '8.0' + - name: Install dependencies with composer php 8.2 + if: matrix.php == '8.2' run: composer update --ignore-platform-reqs --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi - name: Run tests with phpunit without coverage diff --git a/.github/workflows/ci-mysql.yml b/.github/workflows/ci-mysql.yml index 007e03d..b1387fb 100644 --- a/.github/workflows/ci-mysql.yml +++ b/.github/workflows/ci-mysql.yml @@ -21,6 +21,7 @@ jobs: php-version: - "8.0" + - "8.1" mysql-version: - "5.7" @@ -77,8 +78,13 @@ jobs: php${{ matrix.php-version }}-composer-${{ matrix.dependencies }}- - name: Install dependencies with composer + if: matrix.php-version != '8.2' run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi + - name: Install dependencies with composer php 8.2 + if: matrix.php-version == '8.2' + run: composer update --ignore-platform-reqs --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi + - name: Run mysql tests with phpunit env: DB: mysql diff --git a/.github/workflows/ci-pgsql.yml b/.github/workflows/ci-pgsql.yml index 4ee92d9..5447b33 100644 --- a/.github/workflows/ci-pgsql.yml +++ b/.github/workflows/ci-pgsql.yml @@ -20,6 +20,7 @@ jobs: - ubuntu-latest php-version: - "8.0" + - "8.1" pgsql-version: - "10" @@ -78,8 +79,13 @@ jobs: php${{ matrix.php-version }}-composer-${{ matrix.dependencies }}- - name: Install dependencies with composer + if: matrix.php-version != '8.2' run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi + - name: Install dependencies with composer php 8.2 + if: matrix.php-version == '8.2' + run: composer update --ignore-platform-reqs --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi + - name: Run pgsql tests with phpunit env: DB: postgres diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 07e6a55..b766897 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -15,6 +15,7 @@ jobs: php-version: - "8.0" + - "8.1" steps: - name: Checkout uses: actions/checkout@v2 @@ -29,7 +30,7 @@ jobs: php-version: ${{ matrix.php-version }} coverage: pcov tools: pecl - extensions: mbstring, pdo, pdo_sqlite, pdo_pgsql, pdo_sqlsrv, pdo_mysql + extensions: mbstring, pdo, pdo_sqlite, pdo_pgsql, pdo_sqlsrv-5.10.0beta2, pdo_mysql - name: Get Composer Cache Directory id: composer-cache run: echo "::set-output name=dir::$(composer config cache-files-dir)" @@ -39,18 +40,26 @@ jobs: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} restore-keys: ${{ runner.os }}-composer- - - name: Install Dependencies - run: composer install --no-interaction --prefer-dist + - name: Install dependencies with composer + if: matrix.php-versions != '8.2' + run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi + - name: Install dependencies with composer php 8.2 + if: matrix.php-versions == '8.2' + run: composer update --ignore-platform-reqs --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi - name: Execute Tests run: | - vendor/bin/phpunit --coverage-clover=coverage.xml + vendor/bin/phpunit --coverage-clover=coverage.clover - name: Upload coverage to Codecov continue-on-error: true # if is fork uses: codecov/codecov-action@v1 with: token: ${{ secrets.CODECOV_TOKEN }} - file: ./coverage.xml - + file: ./coverage.clover + - name: Upload coverage to Scrutinizer + continue-on-error: true # if is fork + uses: sudo-bot/action-scrutinizer@latest + with: + cli-args: "--format=php-clover coverage.clover" sqlite: name: SQLite PHP ${{ matrix.php-version }} runs-on: ${{ matrix.os }} diff --git a/.scrutinizer.yml b/.scrutinizer.yml new file mode 100644 index 0000000..e629757 --- /dev/null +++ b/.scrutinizer.yml @@ -0,0 +1,21 @@ +checks: + php: true + +filter: + paths: + - "src/*" + +tools: + external_code_coverage: + timeout: 600 # Timeout in seconds. + runs: 2 # How many code coverage submissions Scrutinizer will wait + +build: + nodes: + analysis: + environment: + php: 8.0 + + tests: + override: + - php-scrutinizer-run