Skip to content

Commit ea1e294

Browse files
authored
update phpunit (#186)
* update phpunit * add color
1 parent 0984e0b commit ea1e294

File tree

4 files changed

+17
-4
lines changed

4 files changed

+17
-4
lines changed

.github/workflows/phpunit.yml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,14 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v3
10-
- uses: php-actions/composer@v6
11-
- uses: php-actions/phpunit@v3
10+
- name: setup PHP
11+
uses: shivammathur/setup-php@v2
12+
with:
13+
php-version: "8.3"
14+
# php extensions also listed in tools/docker-dev/web/Dockerfile
15+
extensions: curl,mysql,ldap,pdo,redis
16+
tools: composer:v2
17+
- name: Install dependencies
18+
run: composer install --prefer-dist --no-progress
19+
- name: Run PHPUnit tests
20+
run: vendor/bin/phpunit --colors=always

composer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,8 @@
44
"phpseclib/phpseclib": "3.0.43",
55
"phpmailer/phpmailer": "6.6.4",
66
"hakasapl/phpopenldaper": "1.0.5"
7+
},
8+
"require-dev": {
9+
"phpunit/phpunit": "<12.1"
710
}
811
}

phpunit.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1+
<!-- restrictWarnings="true" -->
12
<phpunit
23
bootstrap="test/unit/bootstrap.php"
34
failOnWarning="true"
45
failOnDeprecation="true"
56
failOnNotice="true"
6-
restrictWarnings="true"
77
>
88
<testsuites>
99
<testsuite name="unit">

tools/docker-dev/web/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ FROM ubuntu:20.04
22

33
# Web Server Setup
44
ARG DEBIAN_FRONTEND=noninteractive
5+
# php extensions also listed in .github/workflows/phpunit.yml
56
RUN apt-get update && apt-get install -y \
67
apache2 \
78
apache2-utils \
@@ -23,4 +24,4 @@ RUN sed -i '/display_errors/c\display_errors = on' /etc/php/7.4/apache2/php.ini
2324
# Start apache2 server
2425
EXPOSE 80
2526

26-
CMD ["apache2ctl", "-D", "FOREGROUND"]
27+
CMD ["apache2ctl", "-D", "FOREGROUND"]

0 commit comments

Comments
 (0)