Skip to content

Commit

Permalink
Upgrade development tools, clean up phpdoc, test PHP8
Browse files Browse the repository at this point in the history
  • Loading branch information
AJenbo committed Oct 18, 2022
1 parent f794fd8 commit 2ee87e6
Show file tree
Hide file tree
Showing 101 changed files with 4,875 additions and 4,168 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Test

on:
push:
branches:
- master
pull_request:
types: [ opened, synchronize ]

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
php: [ '7.4', '8.0' ]
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
tools: composer:v2, cs2pr
coverage: pcov

- name: Get Cache
id: composer-cache
run: echo "::set-output name=dir::$(cd ./application && composer config cache-files-dir)"
- uses: actions/cache@v3
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: composer-${{ hashFiles('**/composer.lock') }}
restore-keys: composer-

- name: Install dependencies
working-directory: ./application
run: composer install

- name: PHPStan
working-directory: ./application
run: vendor/bin/phpstan

- name: PHPUnit
run: application/vendor/bin/phpunit --printer mheap\\GithubActionsReporter\\Printer

- name: Upload coverage to Coveralls
env:
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: application/vendor/bin/php-coveralls

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3

- name: Upload coverage to Codacy
uses: codacy/codacy-analysis-cli-action@v4.2.0

- name: Upload coverage to Codeclimate
uses: paambaati/codeclimate-action@v3.1.0
env:
CC_TEST_REPORTER_ID: dded30dc4b62f393c80ed752f13c7c7efaf748c3573daee0f4040615457ff9c0
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@
/build
/node_modules
/tests/application/theme/cache
/.phpunit.result.cache
33 changes: 0 additions & 33 deletions .travis.yml

This file was deleted.

12 changes: 8 additions & 4 deletions application/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,22 @@
}
},
"require": {
"php": ">=7.1.0",
"php": "^7.4.0|^8.0.0",
"ext-gettext": "*",
"ext-intl": "*",
"ext-mbstring": "*",
"ext-pdo": "*",
"ext-pdo_mysql": "*",
"ext-soap": "*",
"ext-xml": "*",
"guzzlehttp/psr7": "^1.4",
"ajenbo/image.php": "^0.9.3",
"ajenbo/imap.php": "^0.9.1",
"ezyang/htmlpurifier": ">=4.4",
"guzzlehttp/psr7": "^1.4",
"james-heinrich/getid3": "^1.9",
"php-http/guzzle7-adapter": "^1.0",
"phpmailer/phpmailer": ">=5.0.0",
"sentry/sentry": "^1.8",
"sentry/sentry": "^3.9",
"symfony/http-foundation": "^4.0",
"tecnickcom/tcpdf": "^6.2",
"twig/extensions": "^1.5",
Expand All @@ -36,12 +37,15 @@
"require-dev": {
"ext-pdo_sqlite": "*",
"codacy/coverage": "^1.0",
"dms/phpunit-arraysubset-asserts": "^0.4.0",
"friendsofphp/php-cs-fixer": "^3.12",
"mheap/phpunit-github-actions-printer": "^1.5",
"mockery/mockery": "^1.0.0",
"php-coveralls/php-coveralls": "^2.0",
"phpstan/phpstan": "*",
"phpstan/phpstan-mockery": "*",
"phpstan/phpstan-phpunit": "*",
"phpunit/phpunit": "^7.0"
"phpunit/phpunit": "^9.0"
},
"config": {
"preferred-install": "dist",
Expand Down
Loading

0 comments on commit 2ee87e6

Please sign in to comment.