Skip to content

Commit 02d4590

Browse files
committed
Updated phpunit, CI, github configurations
1 parent e1ce1ee commit 02d4590

13 files changed

+23
-88
lines changed

.ci/Dockerfile

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,12 @@ RUN apt-get update && \
1111
RUN apt-get install -y \
1212
libzip-dev \
1313
zip \
14-
&& docker-php-ext-install zip
14+
libyaml-dev \
15+
&& docker-php-ext-install zip
16+
17+
# Install yaml extension for PHP
18+
RUN pecl channel-update pecl.php.net
19+
RUN pecl install yaml && docker-php-ext-enable yaml
1520

1621
# Print PHP version
1722
RUN php -v

.ci/jobs/elastic+elasticsearch-php+7.10.yml

Lines changed: 0 additions & 14 deletions
This file was deleted.

.ci/jobs/elastic+elasticsearch-php+pull-request.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,4 @@
1717
github-hooks: true
1818
status-context: clients-ci
1919
cancel-builds-on-update: true
20+
publishers: []

.ci/packer_cache.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22

33
source /usr/local/bin/bash_standard_lib.sh
44

5-
DOCKER_IMAGES="php:7.4-cli
5+
DOCKER_IMAGES="php:8.0-cli
6+
php:7.4-cli
67
php:7.3-cli
78
php:7.2-cli
89
php:7.1-cli

.ci/test-matrix.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ STACK_VERSION:
33
- 8.0.0-SNAPSHOT
44

55
PHP_VERSION:
6+
- 8.0-cli
67
- 7.4-cli
78
- 7.3-cli
89
- 7.2-cli

.ci/yaml-tests.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,8 @@
33
# Checkout the YAML test from Elasticsearch tag
44
php util/RestSpecRunner.php
55

6+
# Generate the YAML tests for PHPUnit
7+
php util/build_tests.php ${STACK_VERSION} ${TEST_SUITE}
8+
69
# Run YAML tests
7-
vendor/bin/phpunit -c phpunit-yaml-tests.xml
10+
vendor/bin/phpunit -c "phpunit-yaml-${TEST_SUITE}-tests.xml"

.github/workflows/test.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99

1010
strategy:
1111
matrix:
12-
php-version: [7.1, 7.2, 7.3, 7.4]
12+
php-version: [7.1, 7.2, 7.3, 7.4, 8.0]
1313
os: [ubuntu-latest]
1414
es-version: [8.0.0-SNAPSHOT]
1515

@@ -52,7 +52,7 @@ jobs:
5252
run: |
5353
vendor/bin/phpunit -c phpunit.xml.dist
5454
env:
55-
TEST_SUITE: oss
55+
TEST_SUITE: free
5656

5757
- name: Configure sysctl limits
5858
run: |
@@ -70,5 +70,5 @@ jobs:
7070
run: |
7171
vendor/bin/phpunit -c phpunit-integration-tests.xml
7272
env:
73-
TEST_SUITE: oss
73+
TEST_SUITE: free
7474

phpunit-integration-tests.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
verbose="true"
88
beStrictAboutChangesToGlobalState="true"
99
beStrictAboutOutputDuringTests="true"
10+
beStrictAboutTestsThatDoNotTestAnything="false"
1011
>
1112
<testsuites>
1213
<testsuite name="Integration tests">

phpunit-integration.xml

Lines changed: 0 additions & 34 deletions
This file was deleted.

phpunit-yaml-free-tests.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,12 @@
77
verbose="true"
88
beStrictAboutChangesToGlobalState="true"
99
beStrictAboutOutputDuringTests="true"
10+
beStrictAboutTestsThatDoNotTestAnything="false"
1011
>
1112
<php>
1213
<!-- Disable E_USER_DEPRECATED setting E_ALL & ~E_USER_DEPRECATED-->
1314
<ini name="error_reporting" value="16383"/>
15+
<ini name="memory_limit" value="-1" />
1416
</php>
1517
<testsuites>
1618
<testsuite name="Yaml tests">

phpunit-yaml-platinum-tests.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,12 @@
77
verbose="true"
88
beStrictAboutChangesToGlobalState="true"
99
beStrictAboutOutputDuringTests="true"
10+
beStrictAboutTestsThatDoNotTestAnything="false"
1011
>
1112
<php>
12-
<env name="ES_TEST_HOST" value="http://localhost:9200"/>
1313
<!-- Disable E_USER_DEPRECATED setting E_ALL & ~E_USER_DEPRECATED-->
1414
<ini name="error_reporting" value="16383"/>
15+
<ini name="memory_limit" value="-1" />
1516
</php>
1617
<testsuites>
1718
<testsuite name="Yaml tests">

phpunit-yaml-tests.xml

Lines changed: 0 additions & 33 deletions
This file was deleted.

phpunit.xml.dist

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
verbose="true"
88
beStrictAboutChangesToGlobalState="true"
99
beStrictAboutOutputDuringTests="true"
10+
beStrictAboutTestsThatDoNotTestAnything="false"
1011
>
1112
<testsuites>
1213
<testsuite name="Unit tests">

0 commit comments

Comments
 (0)