Skip to content

Commit

Permalink
⚡ CI reshuffle
Browse files Browse the repository at this point in the history
  • Loading branch information
cdosoftei committed May 19, 2023
1 parent 77b9ab8 commit 69d5812
Show file tree
Hide file tree
Showing 8 changed files with 73 additions and 107 deletions.
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: "composer"
directory: "/"
schedule:
interval: "daily"
52 changes: 52 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: CI

on:
push:
pull_request:

jobs:
StaticAnalysis:
name: StaticAnalysis (PHP ${{ matrix.php }} on ${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-20.04
php:
- 7.4
- 8.0
- 8.1
- 8.2
steps:
- uses: actions/checkout@v2
- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
- run: composer install
- run: composer phpstan
- run: composer psalm -- --output-format=github --shepherd

Coverage:
name: Coverage (PHP ${{ matrix.php }} on ${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-20.04
php:
- 7.4
- 8.0
- 8.1
- 8.2
steps:
- uses: actions/checkout@v2
- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
- run: composer install
- run: pecl install pcov
- uses: paambaati/codeclimate-action@v4.0.0
with:
coverageCommand: php -d extension=pcov -d memory_limit=-1 ./vendor/bin/phpunit -c ./etc/phpunit.xml.dist --coverage-clover clover.xml
coverageLocations: clover.xml:clover
debug: true
40 changes: 0 additions & 40 deletions Makefile

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ In order to ensure high code quality, **RTCKit\SIP** uses [PHPStan](https://gith

```sh
php -d memory_limit=-1 ./vendor/bin/phpstan analyse -c ./etc/phpstan.neon -n -vvv --ansi --level=max src
php -d memory_limit=-1 ./vendor/bin/psalm --config=./etc/psalm.xml --show-info=true
php -d memory_limit=-1 ./vendor/bin/psalm --config=./etc/psalm.xml
```

## License
Expand Down
13 changes: 13 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,18 @@
"psr-4": {
"RTCKit\\SIP\\": "tests/"
}
},
"config": {
"allow-plugins": false,
"platform": {
"php": "7.4"
}
},
"scripts": {
"phpstan": "php -d memory_limit=-1 ./vendor/bin/phpstan analyse -c ./etc/phpstan.neon -n -vvv --ansi --level=max src",
"psalm": "php -d memory_limit=-1 ./vendor/bin/psalm --config=./etc/psalm.xml",
"test": "php -d memory_limit=-1 ./vendor/bin/phpunit -c ./etc/phpunit.xml.dist --debug",
"coverage": "php -d extension=pcov -d memory_limit=-1 ./vendor/bin/phpunit -c ./etc/phpunit.xml.dist --coverage-text --coverage-html=reports/coverage",
"profile": "php -d memory_limit=-1 ./examples/99-crude-benchmark.php"
}
}
36 changes: 0 additions & 36 deletions etc/Dockerfile

This file was deleted.

29 changes: 0 additions & 29 deletions etc/Dockerfile.xdebug

This file was deleted.

2 changes: 1 addition & 1 deletion tests/RFC4475/S31101Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public function testShouldParseProperly()
$this->assertEquals('Quoted string \\"\\"', $msg->contact->values[0]->name);

/* an empty subject */
$this->assertEquals('', $msg->subject->values[0]);
$this->assertCount(0, $msg->subject->values);

/* both comma separated and separately listed header field values */
/* a mix of short and long form for the same header field name */
Expand Down

0 comments on commit 69d5812

Please sign in to comment.