adjust tests to new phpunit

This commit is contained in:
Robin Appelman 2021-03-02 19:25:27 +01:00
commit a0abe86651
9 changed files with 97 additions and 23 deletions

65
.github/workflows/ci.yaml vendored Normal file
View file

@ -0,0 +1,65 @@
on: [push, pull_request]
name: CI
jobs:
php-cs-fixer:
name: PHP-CS-Fixer
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@master
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
- name: PHP-CS-Fixer
uses: OskarStark/php-cs-fixer-ga@2.16.7
with:
args: --diff --dry-run --allow-risky yes --stop-on-violation --using-cache=no --path-mode=intersection
phpstan:
name: PHPStan Static Analysis
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
- name: Composer
run: composer install
- env:
BACKEND: smbclient
run: php ./vendor/bin/phpstan analyse --level 2 src
phpunit:
runs-on: ubuntu-20.04
name: Unit tests
strategy:
matrix:
backend:
- smbclient
- libsmbclient
services:
samba:
image: dperson/samba
env:
USER: "test;test"
SHARE: "test;/tmp;yes;no;yes;all;none"
ports:
- 139:139
- 445:445
steps:
- uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
- name: Composer
run: composer install
- name: PHPUnit Tests
run: php ./vendor/bin/phpunit tests