Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade notes rewrite #99

Merged
merged 12 commits into from
Oct 3, 2024
62 changes: 62 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: CI Tests
on: [push, pull_request, workflow_dispatch]

jobs:
PHPUnit:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-latest
php:
- 8.2
- 8.3
- 8.4

steps:
- uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}

- uses: php-actions/composer@v6 # or alternative dependency management


- name: Run PHPUnit
run: vendor/bin/phpunit --coverage-clover ./coverage.xml
env:
XDEBUG_MODE: coverage

- name: Upload to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
verbose: true


cs:
name: Coding standards
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.3
tools: cs2pr, phpcs
coverage: none

- uses: php-actions/composer@v6 # or alternative dependency management

- name: PHP CodeSniffer
run: phpcs -q --no-colors --report=checkstyle | cs2pr

- uses: php-actions/phpstan@v3
with:
path: src/
level: 9
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,10 @@
/cvsmoodle21/
/cvsmoodle22/
/cvsmoodle23/
/vendor/
.phpunit.result.cache
.phpunit.cache
coverage
coverage.txt
.phpcs-cache
coverage.xml
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ Set up is dead easy thanks to a the installation script:

git clone https://github.com/moodlehq/mdlrelease.git
cd mdlrelease
composer install
./install.sh protocol username

protocol: defaults to 'ssh', also accepts 'https'.
Expand Down
Loading