diff --git a/.drone.starlark b/.drone.starlark index 63360bca40ff..f13e21663587 100644 --- a/.drone.starlark +++ b/.drone.starlark @@ -25,12 +25,11 @@ config = { 'phpunit': { 'allDatabases' : { 'phpVersions': [ - '7.1', + '7.2', ] }, 'reducedDatabases' : { 'phpVersions': [ - '7.2', '7.3', ], 'databases': [ @@ -41,7 +40,7 @@ config = { }, 'external-samba-windows' : { 'phpVersions': [ - '7.1', + '7.2', ], 'databases': [ 'sqlite', @@ -60,7 +59,7 @@ config = { }, 'external-other' : { 'phpVersions': [ - '7.1', + '7.2', ], 'databases': [ 'sqlite', @@ -270,7 +269,7 @@ def dependencies(): return pipelines default = { - 'phpVersions': ['7.1'], + 'phpVersions': ['7.2'], } if 'defaults' in config: @@ -468,7 +467,7 @@ def phpstan(): return pipelines default = { - 'phpVersions': ['7.1'], + 'phpVersions': ['7.2'], 'logLevel': '2', } @@ -545,7 +544,7 @@ def phan(): return pipelines default = { - 'phpVersions': ['7.1', '7.2', '7.3'], + 'phpVersions': ['7.2', '7.3'], 'logLevel': '2', } @@ -622,7 +621,7 @@ def litmus(): return pipelines default = { - 'phpVersions': ['7.1'], + 'phpVersions': ['7.2'], 'logLevel': '2' } @@ -788,7 +787,7 @@ def dav(): return pipelines default = { - 'phpVersions': ['7.1'], + 'phpVersions': ['7.2'], 'logLevel': '2' } @@ -886,7 +885,7 @@ def javascript(): default = { 'coverage': True, 'logLevel': '2', - 'phpVersion': '7.1' + 'phpVersion': '7.2' } if 'defaults' in config: @@ -982,7 +981,7 @@ def phptests(testType): errorFound = False default = { - 'phpVersions': ['7.1', '7.2', '7.3'], + 'phpVersions': ['7.2', '7.3'], 'databases': [ 'sqlite', 'mariadb:10.2', 'mariadb:10.3', 'mysql:5.5', 'mysql:5.7', 'mysql:8.0', 'postgres:9.4', 'postgres:10.3', 'oracle' ], @@ -1166,7 +1165,7 @@ def acceptance(): default = { 'federatedServerVersions': [''], 'browsers': ['chrome'], - 'phpVersions': ['7.1'], + 'phpVersions': ['7.2'], 'databases': ['mariadb:10.2'], 'federatedServerNeeded': False, 'filterTags': '', diff --git a/.drone.yml b/.drone.yml index fc107b9b215d..5d01be02a8cd 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,7 +1,7 @@ --- kind: pipeline type: docker -name: install-dependencies-php7.1 +name: install-dependencies-php7.2 platform: os: linux @@ -30,7 +30,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -38,7 +38,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -46,7 +46,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -168,12 +168,12 @@ trigger: - refs/heads/master depends_on: -- install-dependencies-php7.1 +- install-dependencies-php7.2 --- kind: pipeline type: docker -name: phpstan-php7.1 +name: phpstan-php7.2 platform: os: linux @@ -202,7 +202,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -210,7 +210,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -218,7 +218,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -228,7 +228,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -242,7 +242,7 @@ steps: - name: php-phpstan pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make test-php-phpstan @@ -253,92 +253,7 @@ trigger: - refs/heads/master depends_on: -- install-dependencies-php7.1 - ---- -kind: pipeline -type: docker -name: phan-php7.1 - -platform: - os: linux - arch: amd64 - -workspace: - base: /drone - path: src - -steps: -- name: cache-restore - pull: always - image: plugins/s3-cache:1 - settings: - access_key: - from_secret: cache_s3_access_key - endpoint: - from_secret: cache_s3_endpoint - restore: true - secret_key: - from_secret: cache_s3_secret_key - when: - instance: - - drone.owncloud.services - - drone.owncloud.com - -- name: composer-install - pull: always - image: owncloudci/php:7.1 - commands: - - make install-composer-deps - environment: - COMPOSER_HOME: /drone/src/.cache/composer - -- name: vendorbin-install - pull: always - image: owncloudci/php:7.1 - commands: - - make vendor-bin-deps - environment: - COMPOSER_HOME: /drone/src/.cache/composer - -- name: yarn-install - pull: always - image: owncloudci/php:7.1 - commands: - - make install-nodejs-deps - environment: - NPM_CONFIG_CACHE: /drone/src/.cache/npm - YARN_CACHE_FOLDER: /drone/src/.cache/yarn - bower_storage__packages: /drone/src/.cache/bower - -- name: install-server - pull: always - image: owncloudci/php:7.1 - commands: - - bash tests/drone/install-server.sh - - php occ a:l - - php occ config:system:set trusted_domains 1 --value=server - - php occ log:manage --level 2 - - php occ config:list - - php occ security:certificates:import /drone/server.crt - - php occ security:certificates - environment: - DB_TYPE: sqlite - -- name: phan - pull: always - image: owncloudci/php:7.1 - commands: - - make test-php-phan - -trigger: - ref: - - refs/pull/** - - refs/tags/** - - refs/heads/master - -depends_on: -- install-dependencies-php7.1 +- install-dependencies-php7.2 --- kind: pipeline @@ -423,7 +338,7 @@ trigger: - refs/heads/master depends_on: -- install-dependencies-php7.1 +- install-dependencies-php7.2 --- kind: pipeline @@ -508,7 +423,7 @@ trigger: - refs/heads/master depends_on: -- install-dependencies-php7.1 +- install-dependencies-php7.2 --- kind: pipeline @@ -542,7 +457,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -550,7 +465,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -558,7 +473,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -568,7 +483,7 @@ steps: - name: test-js pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make test-js @@ -598,15 +513,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: litmus-php7.1 +name: litmus-php7.2 platform: os: linux @@ -635,7 +549,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -643,7 +557,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -651,7 +565,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -661,7 +575,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -675,13 +589,13 @@ steps: - name: tech-preview pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - php occ config:system:set dav.enable.tech_preview --value=true --type boolean - name: setup-storage pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - mkdir -p /drone/src/work/local_storage - php occ app:enable files_external @@ -694,13 +608,13 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src - name: create-share pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - curl -k -s -u user1:123456 -X MKCOL "https://server/remote.php/webdav/new_folder" - curl -k -s -u user1:123456 "https://server/ocs/v2.php/apps/files_sharing/api/v1/shares" --data "path=/new_folder&shareType=0&permissions=15&name=new_folder&shareWith=admin" @@ -810,7 +724,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -832,15 +746,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: caldav-new-php7.1 +name: caldav-new-php7.2 platform: os: linux @@ -869,7 +782,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -877,7 +790,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -885,7 +798,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -895,7 +808,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -909,13 +822,13 @@ steps: - name: dav-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash apps/dav/tests/ci/caldav/install.sh - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -928,7 +841,7 @@ steps: - name: dav-test pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash apps/dav/tests/ci/caldav/script.sh @@ -950,15 +863,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: caldav-old-php7.1 +name: caldav-old-php7.2 platform: os: linux @@ -987,7 +899,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -995,7 +907,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -1003,7 +915,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -1013,7 +925,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -1027,13 +939,13 @@ steps: - name: dav-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash apps/dav/tests/ci/caldav-old-endpoint/install.sh - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -1046,7 +958,7 @@ steps: - name: dav-test pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash apps/dav/tests/ci/caldav-old-endpoint/script.sh @@ -1068,15 +980,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: carddav-new-php7.1 +name: carddav-new-php7.2 platform: os: linux @@ -1105,7 +1016,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -1113,7 +1024,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -1121,7 +1032,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -1131,7 +1042,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -1145,13 +1056,13 @@ steps: - name: dav-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash apps/dav/tests/ci/carddav/install.sh - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -1164,7 +1075,7 @@ steps: - name: dav-test pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash apps/dav/tests/ci/carddav/script.sh @@ -1186,15 +1097,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: carddav-old-php7.1 +name: carddav-old-php7.2 platform: os: linux @@ -1223,7 +1133,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -1231,7 +1141,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -1239,7 +1149,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -1249,7 +1159,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -1263,13 +1173,13 @@ steps: - name: dav-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash apps/dav/tests/ci/carddav-old-endpoint/install.sh - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -1282,7 +1192,7 @@ steps: - name: dav-test pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash apps/dav/tests/ci/carddav-old-endpoint/script.sh @@ -1304,15 +1214,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-sqlite +name: phpunit-php7.2-sqlite platform: os: linux @@ -1341,7 +1250,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -1349,7 +1258,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -1357,7 +1266,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -1367,7 +1276,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -1381,7 +1290,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -1394,7 +1303,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -1427,15 +1336,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-mariadb10.2 +name: phpunit-php7.2-mariadb10.2 platform: os: linux @@ -1464,7 +1372,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -1472,7 +1380,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -1480,7 +1388,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -1490,7 +1398,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -1504,7 +1412,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -1517,7 +1425,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -1560,15 +1468,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-mariadb10.3 +name: phpunit-php7.2-mariadb10.3 platform: os: linux @@ -1597,7 +1504,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -1605,7 +1512,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -1613,7 +1520,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -1623,7 +1530,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -1637,7 +1544,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -1650,7 +1557,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -1693,15 +1600,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-mysql5.5 +name: phpunit-php7.2-mysql5.5 platform: os: linux @@ -1730,7 +1636,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -1738,7 +1644,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -1746,7 +1652,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -1756,7 +1662,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -1770,7 +1676,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -1783,7 +1689,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -1826,15 +1732,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-mysql5.7 +name: phpunit-php7.2-mysql5.7 platform: os: linux @@ -1863,7 +1768,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -1871,7 +1776,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -1879,7 +1784,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -1889,7 +1794,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -1903,7 +1808,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -1916,7 +1821,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -1959,15 +1864,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-mysql8.0 +name: phpunit-php7.2-mysql8.0 platform: os: linux @@ -1996,7 +1900,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -2004,7 +1908,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -2012,7 +1916,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -2022,7 +1926,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -2036,7 +1940,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -2049,7 +1953,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -2094,15 +1998,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-postgres9.4 +name: phpunit-php7.2-postgres9.4 platform: os: linux @@ -2131,7 +2034,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -2139,7 +2042,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -2147,7 +2050,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -2157,7 +2060,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -2171,7 +2074,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -2184,7 +2087,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -2226,15 +2129,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-postgres10.3 +name: phpunit-php7.2-postgres10.3 platform: os: linux @@ -2263,7 +2165,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -2271,7 +2173,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -2279,7 +2181,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -2289,7 +2191,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -2303,7 +2205,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -2316,7 +2218,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -2358,15 +2260,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-oracle +name: phpunit-php7.2-oracle platform: os: linux @@ -2395,7 +2296,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -2403,7 +2304,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -2411,7 +2312,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -2421,7 +2322,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -2435,7 +2336,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -2448,7 +2349,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -2491,228 +2392,7 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 -- phan-php7.2 -- phan-php7.3 - ---- -kind: pipeline -type: docker -name: phpunit-php7.2-sqlite - -platform: - os: linux - arch: amd64 - -workspace: - base: /drone - path: src - -steps: -- name: cache-restore - pull: always - image: plugins/s3-cache:1 - settings: - access_key: - from_secret: cache_s3_access_key - endpoint: - from_secret: cache_s3_endpoint - restore: true - secret_key: - from_secret: cache_s3_secret_key - when: - instance: - - drone.owncloud.services - - drone.owncloud.com - -- name: composer-install - pull: always - image: owncloudci/php:7.2 - commands: - - make install-composer-deps - environment: - COMPOSER_HOME: /drone/src/.cache/composer - -- name: vendorbin-install - pull: always - image: owncloudci/php:7.2 - commands: - - make vendor-bin-deps - environment: - COMPOSER_HOME: /drone/src/.cache/composer - -- name: yarn-install - pull: always - image: owncloudci/php:7.2 - commands: - - make install-nodejs-deps - environment: - NPM_CONFIG_CACHE: /drone/src/.cache/npm - YARN_CACHE_FOLDER: /drone/src/.cache/yarn - bower_storage__packages: /drone/src/.cache/bower - -- name: install-server - pull: always - image: owncloudci/php:7.2 - commands: - - bash tests/drone/install-server.sh - - php occ a:l - - php occ config:system:set trusted_domains 1 --value=server - - php occ log:manage --level 2 - - php occ config:list - - php occ security:certificates:import /drone/server.crt - - php occ security:certificates - environment: - DB_TYPE: sqlite - -- name: fix-permissions - pull: always - image: owncloudci/php:7.2 - commands: - - chown -R www-data /drone/src - -- name: owncloud-log-server - pull: always - image: owncloud/ubuntu:18.04 - detach: true - commands: - - tail -f /drone/src/data/owncloud.log - -- name: phpunit-tests - pull: always - image: owncloudci/php:7.2 - commands: - - su-exec www-data bash tests/drone/test-phpunit.sh - environment: - COVERAGE: false - DB_TYPE: sqlite - -trigger: - ref: - - refs/pull/** - - refs/tags/** - - refs/heads/master - -depends_on: -- coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 -- phan-php7.2 -- phan-php7.3 - ---- -kind: pipeline -type: docker -name: phpunit-php7.2-mariadb10.2 - -platform: - os: linux - arch: amd64 - -workspace: - base: /drone - path: src - -steps: -- name: cache-restore - pull: always - image: plugins/s3-cache:1 - settings: - access_key: - from_secret: cache_s3_access_key - endpoint: - from_secret: cache_s3_endpoint - restore: true - secret_key: - from_secret: cache_s3_secret_key - when: - instance: - - drone.owncloud.services - - drone.owncloud.com - -- name: composer-install - pull: always - image: owncloudci/php:7.2 - commands: - - make install-composer-deps - environment: - COMPOSER_HOME: /drone/src/.cache/composer - -- name: vendorbin-install - pull: always - image: owncloudci/php:7.2 - commands: - - make vendor-bin-deps - environment: - COMPOSER_HOME: /drone/src/.cache/composer - -- name: yarn-install - pull: always - image: owncloudci/php:7.2 - commands: - - make install-nodejs-deps - environment: - NPM_CONFIG_CACHE: /drone/src/.cache/npm - YARN_CACHE_FOLDER: /drone/src/.cache/yarn - bower_storage__packages: /drone/src/.cache/bower - -- name: install-server - pull: always - image: owncloudci/php:7.2 - commands: - - bash tests/drone/install-server.sh - - php occ a:l - - php occ config:system:set trusted_domains 1 --value=server - - php occ log:manage --level 2 - - php occ config:list - - php occ security:certificates:import /drone/server.crt - - php occ security:certificates - environment: - DB_TYPE: mariadb - -- name: fix-permissions - pull: always - image: owncloudci/php:7.2 - commands: - - chown -R www-data /drone/src - -- name: owncloud-log-server - pull: always - image: owncloud/ubuntu:18.04 - detach: true - commands: - - tail -f /drone/src/data/owncloud.log - -- name: phpunit-tests - pull: always - image: owncloudci/php:7.2 - commands: - - su-exec www-data bash tests/drone/test-phpunit.sh - environment: - COVERAGE: false - DB_TYPE: mariadb - -services: -- name: mariadb - pull: always - image: mariadb:10.2 - environment: - MYSQL_DATABASE: owncloud - MYSQL_PASSWORD: owncloud - MYSQL_ROOT_PASSWORD: owncloud - MYSQL_USER: owncloud - -trigger: - ref: - - refs/pull/** - - refs/tags/** - - refs/heads/master - -depends_on: -- coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 @@ -2816,8 +2496,7 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 @@ -2931,15 +2610,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-sqlite-samba +name: phpunit-php7.2-sqlite-samba platform: os: linux @@ -2968,7 +2646,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -2976,7 +2654,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -2984,7 +2662,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -2994,7 +2672,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -3008,7 +2686,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -3021,7 +2699,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - ls -l /var/cache - mkdir /var/cache/samba @@ -3070,15 +2748,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-sqlite-windows +name: phpunit-php7.2-sqlite-windows platform: os: linux @@ -3107,7 +2784,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -3115,7 +2792,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -3123,7 +2800,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -3133,7 +2810,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -3147,7 +2824,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -3160,7 +2837,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - ls -l /var/cache - mkdir /var/cache/samba @@ -3198,15 +2875,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-sqlite-webdav +name: phpunit-php7.2-sqlite-webdav platform: os: linux @@ -3235,7 +2911,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -3243,7 +2919,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -3251,7 +2927,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -3261,7 +2937,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -3275,7 +2951,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -3288,7 +2964,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -3333,15 +3009,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-sqlite-sftp +name: phpunit-php7.2-sqlite-sftp platform: os: linux @@ -3370,7 +3045,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -3378,7 +3053,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -3386,7 +3061,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -3396,7 +3071,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -3410,7 +3085,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -3423,7 +3098,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -3464,15 +3139,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: phpunit-php7.1-sqlite-scality +name: phpunit-php7.2-sqlite-scality platform: os: linux @@ -3501,7 +3175,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -3509,7 +3183,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -3517,7 +3191,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -3527,7 +3201,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -3541,7 +3215,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/files_primary_s3.git /drone/src/apps/files_primary_s3 - cd /drone/src/apps/files_primary_s3 @@ -3553,7 +3227,7 @@ steps: - name: setup-scality pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - wait-for-it -t 120 scality:8000 - cp /drone/src/apps/files_primary_s3/tests/drone/scality.config.php /drone/src/config @@ -3561,7 +3235,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -3574,7 +3248,7 @@ steps: - name: phpunit-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - su-exec www-data bash tests/drone/test-phpunit.sh environment: @@ -3615,15 +3289,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiAuth-mariadb10.2-php7.1 +name: apiAuth-mariadb10.2-php7.2 platform: os: linux @@ -3652,7 +3325,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -3660,7 +3333,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -3668,7 +3341,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -3678,7 +3351,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -3692,7 +3365,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -3704,7 +3377,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -3717,7 +3390,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -3739,7 +3412,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -3761,15 +3434,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiAuthOcs-mariadb10.2-php7.1 +name: apiAuthOcs-mariadb10.2-php7.2 platform: os: linux @@ -3798,7 +3470,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -3806,7 +3478,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -3814,7 +3486,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -3824,7 +3496,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -3838,7 +3510,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -3850,7 +3522,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -3863,7 +3535,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -3885,7 +3557,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -3907,15 +3579,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiCapabilities-mariadb10.2-php7.1 +name: apiCapabilities-mariadb10.2-php7.2 platform: os: linux @@ -3944,7 +3615,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -3952,7 +3623,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -3960,7 +3631,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -3970,7 +3641,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -3984,7 +3655,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -3996,7 +3667,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -4009,7 +3680,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -4031,7 +3702,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -4053,15 +3724,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiComments-mariadb10.2-php7.1 +name: apiComments-mariadb10.2-php7.2 platform: os: linux @@ -4090,7 +3760,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -4098,7 +3768,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -4106,7 +3776,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -4116,7 +3786,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -4130,7 +3800,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -4142,7 +3812,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -4155,7 +3825,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -4177,7 +3847,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -4199,15 +3869,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiFavorites-mariadb10.2-php7.1 +name: apiFavorites-mariadb10.2-php7.2 platform: os: linux @@ -4236,7 +3905,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -4244,7 +3913,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -4252,7 +3921,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -4262,7 +3931,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -4276,7 +3945,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -4288,7 +3957,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -4301,7 +3970,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -4323,7 +3992,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -4345,15 +4014,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiMain-mariadb10.2-php7.1 +name: apiMain-mariadb10.2-php7.2 platform: os: linux @@ -4382,7 +4050,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -4390,7 +4058,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -4398,7 +4066,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -4408,7 +4076,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -4422,7 +4090,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -4434,7 +4102,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -4447,7 +4115,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -4469,7 +4137,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -4491,15 +4159,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiProvisioning-v1-mariadb10.2-php7.1 +name: apiProvisioning-v1-mariadb10.2-php7.2 platform: os: linux @@ -4528,7 +4195,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -4536,7 +4203,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -4544,7 +4211,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -4554,7 +4221,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -4568,7 +4235,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -4580,7 +4247,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -4593,7 +4260,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -4615,7 +4282,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -4637,15 +4304,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiProvisioning-v2-mariadb10.2-php7.1 +name: apiProvisioning-v2-mariadb10.2-php7.2 platform: os: linux @@ -4674,7 +4340,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -4682,7 +4348,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -4690,7 +4356,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -4700,7 +4366,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -4714,7 +4380,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -4726,7 +4392,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -4739,7 +4405,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -4761,7 +4427,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -4783,15 +4449,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiProvisioningGroups-v1-mariadb10.2-php7.1 +name: apiProvisioningGroups-v1-mariadb10.2-php7.2 platform: os: linux @@ -4820,7 +4485,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -4828,7 +4493,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -4836,7 +4501,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -4846,7 +4511,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -4860,7 +4525,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -4872,7 +4537,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -4885,7 +4550,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -4907,7 +4572,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -4929,15 +4594,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiProvisioningGroups-v2-mariadb10.2-php7.1 +name: apiProvisioningGroups-v2-mariadb10.2-php7.2 platform: os: linux @@ -4966,7 +4630,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -4974,7 +4638,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -4982,7 +4646,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -4992,7 +4656,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -5006,7 +4670,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -5018,7 +4682,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -5031,7 +4695,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -5053,7 +4717,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -5075,15 +4739,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiSharees-mariadb10.2-php7.1 +name: apiSharees-mariadb10.2-php7.2 platform: os: linux @@ -5112,7 +4775,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -5120,7 +4783,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -5128,7 +4791,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -5138,7 +4801,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -5152,7 +4815,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -5164,7 +4827,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -5177,7 +4840,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -5199,7 +4862,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -5221,15 +4884,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiShareManagement-mariadb10.2-php7.1 +name: apiShareManagement-mariadb10.2-php7.2 platform: os: linux @@ -5258,7 +4920,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -5266,7 +4928,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -5274,7 +4936,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -5284,7 +4946,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -5298,7 +4960,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -5310,7 +4972,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -5323,7 +4985,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -5345,7 +5007,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -5367,15 +5029,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiShareManagementBasic-mariadb10.2-php7.1 +name: apiShareManagementBasic-mariadb10.2-php7.2 platform: os: linux @@ -5404,7 +5065,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -5412,7 +5073,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -5420,7 +5081,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -5430,7 +5091,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -5444,7 +5105,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -5456,7 +5117,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -5469,7 +5130,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -5491,7 +5152,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -5513,15 +5174,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiShareOperations-mariadb10.2-php7.1 +name: apiShareOperations-mariadb10.2-php7.2 platform: os: linux @@ -5550,7 +5210,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -5558,7 +5218,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -5566,7 +5226,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -5576,7 +5236,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -5590,7 +5250,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -5602,7 +5262,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -5615,7 +5275,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -5637,7 +5297,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -5659,15 +5319,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiShareReshare-mariadb10.2-php7.1 +name: apiShareReshare-mariadb10.2-php7.2 platform: os: linux @@ -5696,7 +5355,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -5704,7 +5363,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -5712,7 +5371,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -5722,7 +5381,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -5736,7 +5395,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -5748,7 +5407,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -5761,7 +5420,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -5783,7 +5442,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -5805,15 +5464,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiShareUpdate-mariadb10.2-php7.1 +name: apiShareUpdate-mariadb10.2-php7.2 platform: os: linux @@ -5842,7 +5500,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -5850,7 +5508,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -5858,7 +5516,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -5868,7 +5526,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -5882,7 +5540,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -5894,7 +5552,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -5907,7 +5565,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -5929,7 +5587,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -5951,15 +5609,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiTags-mariadb10.2-php7.1 +name: apiTags-mariadb10.2-php7.2 platform: os: linux @@ -5988,7 +5645,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -5996,7 +5653,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -6004,7 +5661,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -6014,7 +5671,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -6028,7 +5685,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -6040,7 +5697,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -6053,7 +5710,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -6075,7 +5732,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -6097,15 +5754,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiTrashbin-mariadb10.2-php7.1 +name: apiTrashbin-mariadb10.2-php7.2 platform: os: linux @@ -6134,7 +5790,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -6142,7 +5798,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -6150,7 +5806,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -6160,7 +5816,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -6174,7 +5830,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -6186,7 +5842,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -6199,7 +5855,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -6221,7 +5877,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -6243,15 +5899,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiVersions-mariadb10.2-php7.1 +name: apiVersions-mariadb10.2-php7.2 platform: os: linux @@ -6280,7 +5935,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -6288,7 +5943,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -6296,7 +5951,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -6306,7 +5961,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -6320,7 +5975,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -6332,7 +5987,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -6345,7 +6000,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -6367,7 +6022,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -6389,15 +6044,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiWebdavLocks-mariadb10.2-php7.1 +name: apiWebdavLocks-mariadb10.2-php7.2 platform: os: linux @@ -6426,7 +6080,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -6434,7 +6088,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -6442,7 +6096,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -6452,7 +6106,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -6466,7 +6120,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -6478,7 +6132,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -6491,7 +6145,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -6513,7 +6167,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -6535,15 +6189,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiWebdavLocks2-mariadb10.2-php7.1 +name: apiWebdavLocks2-mariadb10.2-php7.2 platform: os: linux @@ -6572,7 +6225,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -6580,7 +6233,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -6588,7 +6241,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -6598,7 +6251,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -6612,7 +6265,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -6624,7 +6277,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -6637,7 +6290,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -6659,7 +6312,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -6681,15 +6334,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiWebdavMove-mariadb10.2-php7.1 +name: apiWebdavMove-mariadb10.2-php7.2 platform: os: linux @@ -6718,7 +6370,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -6726,7 +6378,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -6734,7 +6386,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -6744,7 +6396,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -6758,7 +6410,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -6770,7 +6422,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -6783,7 +6435,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -6805,7 +6457,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -6827,15 +6479,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiWebdavOperations-mariadb10.2-php7.1 +name: apiWebdavOperations-mariadb10.2-php7.2 platform: os: linux @@ -6864,7 +6515,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -6872,7 +6523,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -6880,7 +6531,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -6890,7 +6541,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -6904,7 +6555,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -6916,7 +6567,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -6929,7 +6580,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -6951,7 +6602,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -6973,15 +6624,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiWebdavProperties-mariadb10.2-php7.1 +name: apiWebdavProperties-mariadb10.2-php7.2 platform: os: linux @@ -7010,7 +6660,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -7018,7 +6668,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -7026,7 +6676,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -7036,7 +6686,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -7050,7 +6700,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -7062,7 +6712,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -7075,7 +6725,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -7097,7 +6747,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -7119,15 +6769,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiWebdavUpload-mariadb10.2-php7.1 +name: apiWebdavUpload-mariadb10.2-php7.2 platform: os: linux @@ -7156,7 +6805,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -7164,7 +6813,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -7172,7 +6821,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -7182,7 +6831,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -7196,7 +6845,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -7208,7 +6857,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -7221,7 +6870,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -7243,7 +6892,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -7265,15 +6914,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiSharingNotifications-mariadb10.2-php7.1 +name: apiSharingNotifications-mariadb10.2-php7.2 platform: os: linux @@ -7302,7 +6950,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -7310,7 +6958,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -7318,7 +6966,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -7328,7 +6976,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -7342,7 +6990,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -7361,7 +7009,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -7374,7 +7022,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -7396,7 +7044,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -7418,15 +7066,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiFederation-master-mariadb10.2-php7.1 +name: apiFederation-master-mariadb10.2-php7.2 platform: os: linux @@ -7455,7 +7102,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -7463,7 +7110,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -7471,7 +7118,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -7481,7 +7128,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -7504,7 +7151,7 @@ steps: - name: configure-federated pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - cd /drone/federated - php occ a:l @@ -7528,7 +7175,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -7540,7 +7187,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src - chown -R www-data /drone/federated @@ -7554,7 +7201,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -7576,7 +7223,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -7592,7 +7239,7 @@ services: - name: federated pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -7614,15 +7261,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiFederation-10.2.1-mariadb10.2-php7.1 +name: apiFederation-10.2.1-mariadb10.2-php7.2 platform: os: linux @@ -7651,7 +7297,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -7659,7 +7305,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -7667,7 +7313,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -7677,7 +7323,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -7700,7 +7346,7 @@ steps: - name: configure-federated pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - cd /drone/federated - php occ a:l @@ -7724,7 +7370,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -7736,7 +7382,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src - chown -R www-data /drone/federated @@ -7750,7 +7396,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -7772,7 +7418,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -7788,7 +7434,7 @@ services: - name: federated pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -7810,15 +7456,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: cliBackground-mariadb10.2-php7.1 +name: cliBackground-mariadb10.2-php7.2 platform: os: linux @@ -7847,7 +7492,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -7855,7 +7500,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -7863,7 +7508,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -7873,7 +7518,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -7887,7 +7532,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -7899,7 +7544,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -7912,7 +7557,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -7939,7 +7584,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -7961,15 +7606,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: cliMain-mariadb10.2-php7.1 +name: cliMain-mariadb10.2-php7.2 platform: os: linux @@ -7998,7 +7642,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -8006,7 +7650,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -8014,7 +7658,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -8024,7 +7668,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -8038,7 +7682,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -8050,7 +7694,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -8063,7 +7707,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -8090,7 +7734,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -8112,15 +7756,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: cliProvisioning-mariadb10.2-php7.1 +name: cliProvisioning-mariadb10.2-php7.2 platform: os: linux @@ -8149,7 +7792,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -8157,7 +7800,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -8165,7 +7808,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -8175,7 +7818,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -8189,7 +7832,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -8201,7 +7844,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -8214,7 +7857,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -8241,7 +7884,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -8263,15 +7906,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: cliTrashbin-mariadb10.2-php7.1 +name: cliTrashbin-mariadb10.2-php7.2 platform: os: linux @@ -8300,7 +7942,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -8308,7 +7950,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -8316,7 +7958,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -8326,7 +7968,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -8340,7 +7982,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -8352,7 +7994,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -8365,7 +8007,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -8392,7 +8034,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -8414,15 +8056,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: cliAppManagement-mariadb10.2-php7.1 +name: cliAppManagement-mariadb10.2-php7.2 platform: os: linux @@ -8451,7 +8092,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -8459,7 +8100,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -8467,7 +8108,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -8477,7 +8118,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -8491,7 +8132,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -8503,7 +8144,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -8516,7 +8157,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -8538,7 +8179,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -8560,15 +8201,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIAddUsers-chrome-mariadb10.2-php7.1 +name: webUIAddUsers-chrome-mariadb10.2-php7.2 platform: os: linux @@ -8597,7 +8237,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -8605,7 +8245,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -8613,7 +8253,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -8623,7 +8263,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -8637,7 +8277,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -8649,7 +8289,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -8662,7 +8302,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -8699,7 +8339,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -8717,15 +8357,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIAdminSettings-chrome-mariadb10.2-php7.1 +name: webUIAdminSettings-chrome-mariadb10.2-php7.2 platform: os: linux @@ -8754,7 +8393,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -8762,7 +8401,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -8770,7 +8409,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -8780,7 +8419,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -8794,7 +8433,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -8806,7 +8445,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -8819,7 +8458,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -8856,7 +8495,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -8874,15 +8513,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIComments-chrome-mariadb10.2-php7.1 +name: webUIComments-chrome-mariadb10.2-php7.2 platform: os: linux @@ -8911,7 +8549,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -8919,7 +8557,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -8927,7 +8565,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -8937,7 +8575,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -8951,7 +8589,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -8963,7 +8601,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -8976,7 +8614,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -9013,7 +8651,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -9031,15 +8669,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUICreateDelete-chrome-mariadb10.2-php7.1 +name: webUICreateDelete-chrome-mariadb10.2-php7.2 platform: os: linux @@ -9068,7 +8705,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -9076,7 +8713,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -9084,7 +8721,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -9094,7 +8731,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -9108,7 +8745,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -9120,7 +8757,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -9133,7 +8770,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -9170,7 +8807,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -9188,15 +8825,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIFavorites-chrome-mariadb10.2-php7.1 +name: webUIFavorites-chrome-mariadb10.2-php7.2 platform: os: linux @@ -9225,7 +8861,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -9233,7 +8869,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -9241,7 +8877,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -9251,7 +8887,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -9265,7 +8901,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -9277,7 +8913,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -9290,7 +8926,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -9327,7 +8963,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -9345,15 +8981,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIFiles-chrome-mariadb10.2-php7.1 +name: webUIFiles-chrome-mariadb10.2-php7.2 platform: os: linux @@ -9382,7 +9017,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -9390,7 +9025,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -9398,7 +9033,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -9408,7 +9043,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -9422,7 +9057,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -9434,7 +9069,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -9447,7 +9082,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -9484,7 +9119,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -9502,15 +9137,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUILogin-chrome-mariadb10.2-php7.1 +name: webUILogin-chrome-mariadb10.2-php7.2 platform: os: linux @@ -9539,7 +9173,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -9547,7 +9181,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -9555,7 +9189,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -9565,7 +9199,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -9579,7 +9213,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -9591,7 +9225,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -9604,7 +9238,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -9641,7 +9275,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -9659,15 +9293,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIManageQuota-chrome-mariadb10.2-php7.1 +name: webUIManageQuota-chrome-mariadb10.2-php7.2 platform: os: linux @@ -9696,7 +9329,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -9704,7 +9337,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -9712,7 +9345,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -9722,7 +9355,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -9736,7 +9369,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -9748,7 +9381,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -9761,7 +9394,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -9798,7 +9431,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -9816,15 +9449,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIManageUsersGrps-chrome-mariadb10.2-php7.1 +name: webUIManageUsersGrps-chrome-mariadb10.2-php7.2 platform: os: linux @@ -9853,7 +9485,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -9861,7 +9493,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -9869,7 +9501,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -9879,7 +9511,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -9893,7 +9525,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -9905,7 +9537,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -9918,7 +9550,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -9955,7 +9587,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -9973,15 +9605,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIMoveFilesFolder-chrome-mariadb10.2-php7.1 +name: webUIMoveFilesFolder-chrome-mariadb10.2-php7.2 platform: os: linux @@ -10010,7 +9641,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -10018,7 +9649,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -10026,7 +9657,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -10036,7 +9667,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -10050,7 +9681,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -10062,7 +9693,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -10075,7 +9706,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -10112,7 +9743,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -10130,15 +9761,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIPersonalSetting-chrome-mariadb10.2-php7.1 +name: webUIPersonalSetting-chrome-mariadb10.2-php7.2 platform: os: linux @@ -10167,7 +9797,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -10175,7 +9805,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -10183,7 +9813,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -10193,7 +9823,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -10207,7 +9837,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -10219,7 +9849,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -10232,7 +9862,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -10269,7 +9899,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -10287,15 +9917,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIRenameFiles-chrome-mariadb10.2-php7.1 +name: webUIRenameFiles-chrome-mariadb10.2-php7.2 platform: os: linux @@ -10324,7 +9953,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -10332,7 +9961,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -10340,7 +9969,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -10350,7 +9979,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -10364,7 +9993,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -10376,7 +10005,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -10389,7 +10018,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -10426,7 +10055,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -10444,15 +10073,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIRenameFolders-chrome-mariadb10.2-php7.1 +name: webUIRenameFolders-chrome-mariadb10.2-php7.2 platform: os: linux @@ -10481,7 +10109,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -10489,7 +10117,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -10497,7 +10125,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -10507,7 +10135,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -10521,7 +10149,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -10533,7 +10161,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -10546,7 +10174,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -10583,7 +10211,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -10601,15 +10229,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIRestrictSharing-chrome-mariadb10.2-php7.1 +name: webUIRestrictSharing-chrome-mariadb10.2-php7.2 platform: os: linux @@ -10638,7 +10265,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -10646,7 +10273,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -10654,7 +10281,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -10664,7 +10291,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -10678,7 +10305,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -10690,7 +10317,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -10703,7 +10330,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -10740,7 +10367,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -10758,15 +10385,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISettingsMenu-chrome-mariadb10.2-php7.1 +name: webUISettingsMenu-chrome-mariadb10.2-php7.2 platform: os: linux @@ -10795,7 +10421,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -10803,7 +10429,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -10811,7 +10437,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -10821,7 +10447,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -10835,7 +10461,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -10847,7 +10473,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -10860,7 +10486,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -10897,7 +10523,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -10915,15 +10541,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISharingAcceptSh-chrome-mariadb10.2-php7.1 +name: webUISharingAcceptSh-chrome-mariadb10.2-php7.2 platform: os: linux @@ -10952,7 +10577,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -10960,7 +10585,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -10968,7 +10593,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -10978,7 +10603,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -10992,7 +10617,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -11004,7 +10629,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -11017,7 +10642,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -11054,7 +10679,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -11072,15 +10697,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISharingAutocomp-chrome-mariadb10.2-php7.1 +name: webUISharingAutocomp-chrome-mariadb10.2-php7.2 platform: os: linux @@ -11109,7 +10733,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -11117,7 +10741,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -11125,7 +10749,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -11135,7 +10759,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -11149,7 +10773,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -11161,7 +10785,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -11174,7 +10798,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -11211,7 +10835,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -11229,15 +10853,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISharingIntGroup-chrome-mariadb10.2-php7.1 +name: webUISharingIntGroup-chrome-mariadb10.2-php7.2 platform: os: linux @@ -11266,7 +10889,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -11274,7 +10897,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -11282,7 +10905,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -11292,7 +10915,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -11306,7 +10929,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -11318,7 +10941,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -11331,7 +10954,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -11368,7 +10991,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -11386,15 +11009,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISharingIntUsers-chrome-mariadb10.2-php7.1 +name: webUISharingIntUsers-chrome-mariadb10.2-php7.2 platform: os: linux @@ -11423,7 +11045,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -11431,7 +11053,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -11439,7 +11061,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -11449,7 +11071,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -11463,7 +11085,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -11475,7 +11097,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -11488,7 +11110,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -11525,7 +11147,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -11543,15 +11165,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISharingPublic-chrome-mariadb10.2-php7.1 +name: webUISharingPublic-chrome-mariadb10.2-php7.2 platform: os: linux @@ -11580,7 +11201,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -11588,7 +11209,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -11596,7 +11217,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -11606,7 +11227,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -11620,7 +11241,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -11632,7 +11253,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -11645,7 +11266,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -11682,7 +11303,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -11700,15 +11321,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUITags-chrome-mariadb10.2-php7.1 +name: webUITags-chrome-mariadb10.2-php7.2 platform: os: linux @@ -11737,7 +11357,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -11745,7 +11365,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -11753,7 +11373,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -11763,7 +11383,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -11777,7 +11397,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -11789,7 +11409,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -11802,7 +11422,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -11839,7 +11459,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -11857,15 +11477,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUITrashbin-chrome-mariadb10.2-php7.1 +name: webUITrashbin-chrome-mariadb10.2-php7.2 platform: os: linux @@ -11894,7 +11513,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -11902,7 +11521,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -11910,7 +11529,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -11920,7 +11539,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -11934,7 +11553,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -11946,7 +11565,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -11959,7 +11578,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -11996,7 +11615,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -12014,15 +11633,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIUpload-chrome-mariadb10.2-php7.1 +name: webUIUpload-chrome-mariadb10.2-php7.2 platform: os: linux @@ -12051,7 +11669,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -12059,7 +11677,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -12067,7 +11685,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -12077,7 +11695,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -12091,7 +11709,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -12103,7 +11721,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -12116,7 +11734,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -12153,7 +11771,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -12171,15 +11789,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIWebdavLockProt-chrome-mariadb10.2-php7.1 +name: webUIWebdavLockProt-chrome-mariadb10.2-php7.2 platform: os: linux @@ -12208,7 +11825,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -12216,7 +11833,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -12224,7 +11841,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -12234,7 +11851,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -12248,7 +11865,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -12260,7 +11877,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -12273,7 +11890,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -12310,7 +11927,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -12328,15 +11945,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIWebdavLocks-chrome-mariadb10.2-php7.1 +name: webUIWebdavLocks-chrome-mariadb10.2-php7.2 platform: os: linux @@ -12365,7 +11981,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -12373,7 +11989,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -12381,7 +11997,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -12391,7 +12007,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -12405,7 +12021,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -12417,7 +12033,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -12430,7 +12046,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -12467,7 +12083,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -12485,15 +12101,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISharingNotify-chrome-mariadb10.2-php7.1 +name: webUISharingNotify-chrome-mariadb10.2-php7.2 platform: os: linux @@ -12522,7 +12137,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -12530,7 +12145,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -12538,7 +12153,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -12548,7 +12163,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -12562,7 +12177,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -12581,7 +12196,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -12594,7 +12209,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -12631,7 +12246,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -12649,15 +12264,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISharingExt-master-chrome-mariadb10.2-php7.1 +name: webUISharingExt-master-chrome-mariadb10.2-php7.2 platform: os: linux @@ -12686,7 +12300,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -12694,7 +12308,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -12702,7 +12316,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -12712,7 +12326,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -12735,7 +12349,7 @@ steps: - name: configure-federated pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - cd /drone/federated - php occ a:l @@ -12759,7 +12373,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -12771,7 +12385,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src - chown -R www-data /drone/federated @@ -12785,7 +12399,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -12817,7 +12431,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -12833,7 +12447,7 @@ services: - name: federated pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -12855,15 +12469,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUISharingExt-10.2.1-chrome-mariadb10.2-php7.1 +name: webUISharingExt-10.2.1-chrome-mariadb10.2-php7.2 platform: os: linux @@ -12892,7 +12505,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -12900,7 +12513,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -12908,7 +12521,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -12918,7 +12531,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -12941,7 +12554,7 @@ steps: - name: configure-federated pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - cd /drone/federated - php occ a:l @@ -12965,7 +12578,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -12977,7 +12590,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src - chown -R www-data /drone/federated @@ -12991,7 +12604,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -13023,7 +12636,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -13039,7 +12652,7 @@ services: - name: federated pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -13061,15 +12674,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIFfSmoke-3-1-firefox-mariadb10.2-php7.1 +name: webUIFfSmoke-3-1-firefox-mariadb10.2-php7.2 platform: os: linux @@ -13098,7 +12710,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -13106,7 +12718,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -13114,7 +12726,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -13124,7 +12736,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -13138,7 +12750,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -13150,7 +12762,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -13163,7 +12775,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -13203,7 +12815,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -13221,15 +12833,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIFfSmoke-3-2-firefox-mariadb10.2-php7.1 +name: webUIFfSmoke-3-2-firefox-mariadb10.2-php7.2 platform: os: linux @@ -13258,7 +12869,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -13266,7 +12877,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -13274,7 +12885,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -13284,7 +12895,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -13298,7 +12909,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -13310,7 +12921,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -13323,7 +12934,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -13363,7 +12974,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -13381,15 +12992,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIFfSmoke-3-3-firefox-mariadb10.2-php7.1 +name: webUIFfSmoke-3-3-firefox-mariadb10.2-php7.2 platform: os: linux @@ -13418,7 +13028,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -13426,7 +13036,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -13434,7 +13044,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -13444,7 +13054,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -13458,7 +13068,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -13470,7 +13080,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -13483,7 +13093,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -13523,7 +13133,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -13541,15 +13151,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIProxySmoke-3-1-chrome-mariadb10.2-php7.1 +name: webUIProxySmoke-3-1-chrome-mariadb10.2-php7.2 platform: os: linux @@ -13578,7 +13187,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -13586,7 +13195,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -13594,7 +13203,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -13604,7 +13213,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -13619,7 +13228,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -13631,7 +13240,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -13644,7 +13253,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -13689,7 +13298,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -13707,15 +13316,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIProxySmoke-3-2-chrome-mariadb10.2-php7.1 +name: webUIProxySmoke-3-2-chrome-mariadb10.2-php7.2 platform: os: linux @@ -13744,7 +13352,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -13752,7 +13360,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -13760,7 +13368,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -13770,7 +13378,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -13785,7 +13393,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -13797,7 +13405,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -13810,7 +13418,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -13855,7 +13463,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -13873,15 +13481,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: webUIProxySmoke-3-3-chrome-mariadb10.2-php7.1 +name: webUIProxySmoke-3-3-chrome-mariadb10.2-php7.2 platform: os: linux @@ -13910,7 +13517,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -13918,7 +13525,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -13926,7 +13533,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -13936,7 +13543,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -13951,7 +13558,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -13963,7 +13570,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -13976,7 +13583,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -14021,7 +13628,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -14039,15 +13646,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiProxySmoke-3-1-mariadb10.2-php7.1 +name: apiProxySmoke-3-1-mariadb10.2-php7.2 platform: os: linux @@ -14076,7 +13682,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -14084,7 +13690,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -14092,7 +13698,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -14102,7 +13708,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -14117,7 +13723,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -14129,7 +13735,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -14142,7 +13748,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -14172,7 +13778,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -14190,15 +13796,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiProxySmoke-3-2-mariadb10.2-php7.1 +name: apiProxySmoke-3-2-mariadb10.2-php7.2 platform: os: linux @@ -14227,7 +13832,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -14235,7 +13840,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -14243,7 +13848,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -14253,7 +13858,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -14268,7 +13873,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -14280,7 +13885,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -14293,7 +13898,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -14323,7 +13928,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -14341,15 +13946,14 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 --- kind: pipeline type: docker -name: apiProxySmoke-3-3-mariadb10.2-php7.1 +name: apiProxySmoke-3-3-mariadb10.2-php7.2 platform: os: linux @@ -14378,7 +13982,7 @@ steps: - name: composer-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-composer-deps environment: @@ -14386,7 +13990,7 @@ steps: - name: vendorbin-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make vendor-bin-deps environment: @@ -14394,7 +13998,7 @@ steps: - name: yarn-install pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - make install-nodejs-deps environment: @@ -14404,7 +14008,7 @@ steps: - name: install-server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - bash tests/drone/install-server.sh - php occ a:l @@ -14419,7 +14023,7 @@ steps: - name: install-extra-apps pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - git clone https://github.com/owncloud/testing.git /drone/src/apps/testing - cd /drone/src/apps/testing @@ -14431,7 +14035,7 @@ steps: - name: fix-permissions pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - chown -R www-data /drone/src @@ -14444,7 +14048,7 @@ steps: - name: acceptance-tests pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 commands: - touch /drone/saved-settings.sh - . /drone/saved-settings.sh @@ -14474,7 +14078,7 @@ services: - name: server pull: always - image: owncloudci/php:7.1 + image: owncloudci/php:7.2 command: - /usr/local/bin/apachectl - -e @@ -14492,8 +14096,7 @@ trigger: depends_on: - coding-standard-php7.3 -- phpstan-php7.1 -- phan-php7.1 +- phpstan-php7.2 - phan-php7.2 - phan-php7.3 @@ -14528,98 +14131,96 @@ trigger: depends_on: - test-javascript -- litmus-php7.1 -- caldav-new-php7.1 -- caldav-old-php7.1 -- carddav-new-php7.1 -- carddav-old-php7.1 -- phpunit-php7.1-sqlite -- phpunit-php7.1-mariadb10.2 -- phpunit-php7.1-mariadb10.3 -- phpunit-php7.1-mysql5.5 -- phpunit-php7.1-mysql5.7 -- phpunit-php7.1-mysql8.0 -- phpunit-php7.1-postgres9.4 -- phpunit-php7.1-postgres10.3 -- phpunit-php7.1-oracle +- litmus-php7.2 +- caldav-new-php7.2 +- caldav-old-php7.2 +- carddav-new-php7.2 +- carddav-old-php7.2 - phpunit-php7.2-sqlite - phpunit-php7.2-mariadb10.2 +- phpunit-php7.2-mariadb10.3 +- phpunit-php7.2-mysql5.5 +- phpunit-php7.2-mysql5.7 +- phpunit-php7.2-mysql8.0 +- phpunit-php7.2-postgres9.4 +- phpunit-php7.2-postgres10.3 +- phpunit-php7.2-oracle - phpunit-php7.3-sqlite - phpunit-php7.3-mariadb10.2 -- phpunit-php7.1-sqlite-samba -- phpunit-php7.1-sqlite-windows -- phpunit-php7.1-sqlite-webdav -- phpunit-php7.1-sqlite-sftp -- phpunit-php7.1-sqlite-scality -- apiAuth-mariadb10.2-php7.1 -- apiAuthOcs-mariadb10.2-php7.1 -- apiCapabilities-mariadb10.2-php7.1 -- apiComments-mariadb10.2-php7.1 -- apiFavorites-mariadb10.2-php7.1 -- apiMain-mariadb10.2-php7.1 -- apiProvisioning-v1-mariadb10.2-php7.1 -- apiProvisioning-v2-mariadb10.2-php7.1 -- apiProvisioningGroups-v1-mariadb10.2-php7.1 -- apiProvisioningGroups-v2-mariadb10.2-php7.1 -- apiSharees-mariadb10.2-php7.1 -- apiShareManagement-mariadb10.2-php7.1 -- apiShareManagementBasic-mariadb10.2-php7.1 -- apiShareOperations-mariadb10.2-php7.1 -- apiShareReshare-mariadb10.2-php7.1 -- apiShareUpdate-mariadb10.2-php7.1 -- apiTags-mariadb10.2-php7.1 -- apiTrashbin-mariadb10.2-php7.1 -- apiVersions-mariadb10.2-php7.1 -- apiWebdavLocks-mariadb10.2-php7.1 -- apiWebdavLocks2-mariadb10.2-php7.1 -- apiWebdavMove-mariadb10.2-php7.1 -- apiWebdavOperations-mariadb10.2-php7.1 -- apiWebdavProperties-mariadb10.2-php7.1 -- apiWebdavUpload-mariadb10.2-php7.1 -- apiSharingNotifications-mariadb10.2-php7.1 -- apiFederation-master-mariadb10.2-php7.1 -- apiFederation-10.2.1-mariadb10.2-php7.1 -- cliBackground-mariadb10.2-php7.1 -- cliMain-mariadb10.2-php7.1 -- cliProvisioning-mariadb10.2-php7.1 -- cliTrashbin-mariadb10.2-php7.1 -- cliAppManagement-mariadb10.2-php7.1 -- webUIAddUsers-chrome-mariadb10.2-php7.1 -- webUIAdminSettings-chrome-mariadb10.2-php7.1 -- webUIComments-chrome-mariadb10.2-php7.1 -- webUICreateDelete-chrome-mariadb10.2-php7.1 -- webUIFavorites-chrome-mariadb10.2-php7.1 -- webUIFiles-chrome-mariadb10.2-php7.1 -- webUILogin-chrome-mariadb10.2-php7.1 -- webUIManageQuota-chrome-mariadb10.2-php7.1 -- webUIManageUsersGrps-chrome-mariadb10.2-php7.1 -- webUIMoveFilesFolder-chrome-mariadb10.2-php7.1 -- webUIPersonalSetting-chrome-mariadb10.2-php7.1 -- webUIRenameFiles-chrome-mariadb10.2-php7.1 -- webUIRenameFolders-chrome-mariadb10.2-php7.1 -- webUIRestrictSharing-chrome-mariadb10.2-php7.1 -- webUISettingsMenu-chrome-mariadb10.2-php7.1 -- webUISharingAcceptSh-chrome-mariadb10.2-php7.1 -- webUISharingAutocomp-chrome-mariadb10.2-php7.1 -- webUISharingIntGroup-chrome-mariadb10.2-php7.1 -- webUISharingIntUsers-chrome-mariadb10.2-php7.1 -- webUISharingPublic-chrome-mariadb10.2-php7.1 -- webUITags-chrome-mariadb10.2-php7.1 -- webUITrashbin-chrome-mariadb10.2-php7.1 -- webUIUpload-chrome-mariadb10.2-php7.1 -- webUIWebdavLockProt-chrome-mariadb10.2-php7.1 -- webUIWebdavLocks-chrome-mariadb10.2-php7.1 -- webUISharingNotify-chrome-mariadb10.2-php7.1 -- webUISharingExt-master-chrome-mariadb10.2-php7.1 -- webUISharingExt-10.2.1-chrome-mariadb10.2-php7.1 -- webUIFfSmoke-3-1-firefox-mariadb10.2-php7.1 -- webUIFfSmoke-3-2-firefox-mariadb10.2-php7.1 -- webUIFfSmoke-3-3-firefox-mariadb10.2-php7.1 -- webUIProxySmoke-3-1-chrome-mariadb10.2-php7.1 -- webUIProxySmoke-3-2-chrome-mariadb10.2-php7.1 -- webUIProxySmoke-3-3-chrome-mariadb10.2-php7.1 -- apiProxySmoke-3-1-mariadb10.2-php7.1 -- apiProxySmoke-3-2-mariadb10.2-php7.1 -- apiProxySmoke-3-3-mariadb10.2-php7.1 +- phpunit-php7.2-sqlite-samba +- phpunit-php7.2-sqlite-windows +- phpunit-php7.2-sqlite-webdav +- phpunit-php7.2-sqlite-sftp +- phpunit-php7.2-sqlite-scality +- apiAuth-mariadb10.2-php7.2 +- apiAuthOcs-mariadb10.2-php7.2 +- apiCapabilities-mariadb10.2-php7.2 +- apiComments-mariadb10.2-php7.2 +- apiFavorites-mariadb10.2-php7.2 +- apiMain-mariadb10.2-php7.2 +- apiProvisioning-v1-mariadb10.2-php7.2 +- apiProvisioning-v2-mariadb10.2-php7.2 +- apiProvisioningGroups-v1-mariadb10.2-php7.2 +- apiProvisioningGroups-v2-mariadb10.2-php7.2 +- apiSharees-mariadb10.2-php7.2 +- apiShareManagement-mariadb10.2-php7.2 +- apiShareManagementBasic-mariadb10.2-php7.2 +- apiShareOperations-mariadb10.2-php7.2 +- apiShareReshare-mariadb10.2-php7.2 +- apiShareUpdate-mariadb10.2-php7.2 +- apiTags-mariadb10.2-php7.2 +- apiTrashbin-mariadb10.2-php7.2 +- apiVersions-mariadb10.2-php7.2 +- apiWebdavLocks-mariadb10.2-php7.2 +- apiWebdavLocks2-mariadb10.2-php7.2 +- apiWebdavMove-mariadb10.2-php7.2 +- apiWebdavOperations-mariadb10.2-php7.2 +- apiWebdavProperties-mariadb10.2-php7.2 +- apiWebdavUpload-mariadb10.2-php7.2 +- apiSharingNotifications-mariadb10.2-php7.2 +- apiFederation-master-mariadb10.2-php7.2 +- apiFederation-10.2.1-mariadb10.2-php7.2 +- cliBackground-mariadb10.2-php7.2 +- cliMain-mariadb10.2-php7.2 +- cliProvisioning-mariadb10.2-php7.2 +- cliTrashbin-mariadb10.2-php7.2 +- cliAppManagement-mariadb10.2-php7.2 +- webUIAddUsers-chrome-mariadb10.2-php7.2 +- webUIAdminSettings-chrome-mariadb10.2-php7.2 +- webUIComments-chrome-mariadb10.2-php7.2 +- webUICreateDelete-chrome-mariadb10.2-php7.2 +- webUIFavorites-chrome-mariadb10.2-php7.2 +- webUIFiles-chrome-mariadb10.2-php7.2 +- webUILogin-chrome-mariadb10.2-php7.2 +- webUIManageQuota-chrome-mariadb10.2-php7.2 +- webUIManageUsersGrps-chrome-mariadb10.2-php7.2 +- webUIMoveFilesFolder-chrome-mariadb10.2-php7.2 +- webUIPersonalSetting-chrome-mariadb10.2-php7.2 +- webUIRenameFiles-chrome-mariadb10.2-php7.2 +- webUIRenameFolders-chrome-mariadb10.2-php7.2 +- webUIRestrictSharing-chrome-mariadb10.2-php7.2 +- webUISettingsMenu-chrome-mariadb10.2-php7.2 +- webUISharingAcceptSh-chrome-mariadb10.2-php7.2 +- webUISharingAutocomp-chrome-mariadb10.2-php7.2 +- webUISharingIntGroup-chrome-mariadb10.2-php7.2 +- webUISharingIntUsers-chrome-mariadb10.2-php7.2 +- webUISharingPublic-chrome-mariadb10.2-php7.2 +- webUITags-chrome-mariadb10.2-php7.2 +- webUITrashbin-chrome-mariadb10.2-php7.2 +- webUIUpload-chrome-mariadb10.2-php7.2 +- webUIWebdavLockProt-chrome-mariadb10.2-php7.2 +- webUIWebdavLocks-chrome-mariadb10.2-php7.2 +- webUISharingNotify-chrome-mariadb10.2-php7.2 +- webUISharingExt-master-chrome-mariadb10.2-php7.2 +- webUISharingExt-10.2.1-chrome-mariadb10.2-php7.2 +- webUIFfSmoke-3-1-firefox-mariadb10.2-php7.2 +- webUIFfSmoke-3-2-firefox-mariadb10.2-php7.2 +- webUIFfSmoke-3-3-firefox-mariadb10.2-php7.2 +- webUIProxySmoke-3-1-chrome-mariadb10.2-php7.2 +- webUIProxySmoke-3-2-chrome-mariadb10.2-php7.2 +- webUIProxySmoke-3-3-chrome-mariadb10.2-php7.2 +- apiProxySmoke-3-1-mariadb10.2-php7.2 +- apiProxySmoke-3-2-mariadb10.2-php7.2 +- apiProxySmoke-3-3-mariadb10.2-php7.2 ... diff --git a/apps/comments/tests/unit/ActivityListenerTest.php b/apps/comments/tests/unit/ActivityListenerTest.php index 6f81cc1da7d6..f4fd1bffbb09 100644 --- a/apps/comments/tests/unit/ActivityListenerTest.php +++ b/apps/comments/tests/unit/ActivityListenerTest.php @@ -71,7 +71,7 @@ class ActivityListenerTest extends \Test\TestCase { */ private $activityManager; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->activityManager = $this->createMock(IManager::class); diff --git a/apps/comments/tests/unit/Dav/CommentsNodeTest.php b/apps/comments/tests/unit/Dav/CommentsNodeTest.php index 8f866fe08332..37a25f9c24aa 100644 --- a/apps/comments/tests/unit/Dav/CommentsNodeTest.php +++ b/apps/comments/tests/unit/Dav/CommentsNodeTest.php @@ -35,7 +35,7 @@ class CommentsNodeTest extends \Test\TestCase { protected $logger; protected $userSession; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->commentsManager = $this->createMock('\OCP\Comments\ICommentsManager'); @@ -84,9 +84,10 @@ public function testDelete() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDeleteForbidden() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $user = $this->createMock('\OCP\IUser'); $user->expects($this->once()) @@ -124,9 +125,10 @@ public function testGetName() { } /** - * @expectedException \Sabre\DAV\Exception\MethodNotAllowed */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\MethodNotAllowed::class); + $this->node->setName('666'); } @@ -167,10 +169,11 @@ public function testUpdateComment() { } /** - * @expectedException Exception - * @expectedExceptionMessage buh! */ public function testUpdateCommentLogException() { + $this->expectException(\Exception::class); + $this->expectExceptionMessage('buh!'); + $msg = null; $user = $this->createMock('\OCP\IUser'); @@ -206,10 +209,11 @@ public function testUpdateCommentLogException() { } /** - * @expectedException \Sabre\DAV\Exception\BadRequest - * @expectedExceptionMessage Message exceeds allowed character limit of */ public function testUpdateCommentMessageTooLongException() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $this->expectExceptionMessage('Message exceeds allowed character limit of'); + $user = $this->createMock('\OCP\IUser'); $user->expects($this->once()) @@ -243,9 +247,10 @@ public function testUpdateCommentMessageTooLongException() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testUpdateForbiddenByUser() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $msg = 'HaXX0r'; $user = $this->createMock('\OCP\IUser'); @@ -276,9 +281,10 @@ public function testUpdateForbiddenByUser() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testUpdateForbiddenByType() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $msg = 'HaXX0r'; $user = $this->createMock('\OCP\IUser'); @@ -304,9 +310,10 @@ public function testUpdateForbiddenByType() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testUpdateForbiddenByNotLoggedIn() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $msg = 'HaXX0r'; $this->userSession->expects($this->once()) diff --git a/apps/comments/tests/unit/Dav/CommentsPluginTest.php b/apps/comments/tests/unit/Dav/CommentsPluginTest.php index 16666f01a484..400720e4523a 100644 --- a/apps/comments/tests/unit/Dav/CommentsPluginTest.php +++ b/apps/comments/tests/unit/Dav/CommentsPluginTest.php @@ -44,7 +44,7 @@ class CommentsPluginTest extends \Test\TestCase { /** @var CommentsPluginImplementation */ private $plugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') ->disableOriginalConstructor() @@ -155,9 +155,10 @@ public function testCreateComment() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testCreateCommentInvalidObject() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $commentData = [ 'actorType' => 'users', 'verb' => 'comment', @@ -235,9 +236,10 @@ public function testCreateCommentInvalidObject() { } /** - * @expectedException \Sabre\DAV\Exception\BadRequest */ public function testCreateCommentInvalidActor() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $commentData = [ 'actorType' => 'robots', 'verb' => 'comment', @@ -321,9 +323,10 @@ public function testCreateCommentInvalidActor() { } /** - * @expectedException \Sabre\DAV\Exception\UnsupportedMediaType */ public function testCreateCommentUnsupportedMediaType() { + $this->expectException(\Sabre\DAV\Exception\UnsupportedMediaType::class); + $commentData = [ 'actorType' => 'users', 'verb' => 'comment', @@ -407,9 +410,10 @@ public function testCreateCommentUnsupportedMediaType() { } /** - * @expectedException \Sabre\DAV\Exception\BadRequest */ public function testCreateCommentInvalidPayload() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $commentData = [ 'actorType' => 'users', 'verb' => '', @@ -499,10 +503,11 @@ public function testCreateCommentInvalidPayload() { } /** - * @expectedException \Sabre\DAV\Exception\BadRequest - * @expectedExceptionMessage Message exceeds allowed character limit of */ public function testCreateCommentMessageTooLong() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $this->expectExceptionMessage('Message exceeds allowed character limit of'); + $commentData = [ 'actorType' => 'users', 'verb' => 'comment', @@ -591,9 +596,10 @@ public function testCreateCommentMessageTooLong() { } /** - * @expectedException \Sabre\DAV\Exception\ReportNotSupported */ public function testOnReportInvalidNode() { + $this->expectException(\Sabre\DAV\Exception\ReportNotSupported::class); + $path = 'totally/unrelated/13'; $this->tree->expects($this->any()) @@ -610,9 +616,10 @@ public function testOnReportInvalidNode() { } /** - * @expectedException \Sabre\DAV\Exception\ReportNotSupported */ public function testOnReportInvalidReportName() { + $this->expectException(\Sabre\DAV\Exception\ReportNotSupported::class); + $path = 'comments/files/42'; $this->tree->expects($this->any()) diff --git a/apps/comments/tests/unit/Dav/EntityCollectionTest.php b/apps/comments/tests/unit/Dav/EntityCollectionTest.php index 460283752a47..637a93ddb34d 100644 --- a/apps/comments/tests/unit/Dav/EntityCollectionTest.php +++ b/apps/comments/tests/unit/Dav/EntityCollectionTest.php @@ -46,7 +46,7 @@ class EntityCollectionTest extends \Test\TestCase { /** @var EventDispatcherInterface | \PHPUnit_Framework_MockObject_MockObject */ private $dispatcher; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->commentsManager = $this->createMock(ICommentsManager::class); @@ -81,9 +81,10 @@ public function testGetChild(): void { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetChildException(): void { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $this->commentsManager->expects($this->once()) ->method('get') ->with('55') diff --git a/apps/comments/tests/unit/Dav/EntityTypeCollectionTest.php b/apps/comments/tests/unit/Dav/EntityTypeCollectionTest.php index cd8c164ce347..ad70bf6cf08a 100644 --- a/apps/comments/tests/unit/Dav/EntityTypeCollectionTest.php +++ b/apps/comments/tests/unit/Dav/EntityTypeCollectionTest.php @@ -48,7 +48,7 @@ class EntityTypeCollectionTest extends \Test\TestCase { /** @var EventDispatcherInterface | \PHPUnit_Framework_MockObject_MockObject */ private $dispatcher; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->commentsManager = $this->createMock(ICommentsManager::class); @@ -89,16 +89,18 @@ public function testGetChild() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetChildException() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $this->collection->getChild('17'); } /** - * @expectedException \Sabre\DAV\Exception\MethodNotAllowed */ public function testGetChildren() { + $this->expectException(\Sabre\DAV\Exception\MethodNotAllowed::class); + $this->collection->getChildren(); } } diff --git a/apps/comments/tests/unit/Dav/RootCollectionTest.php b/apps/comments/tests/unit/Dav/RootCollectionTest.php index 7714a8cbbb40..cba32f419623 100644 --- a/apps/comments/tests/unit/Dav/RootCollectionTest.php +++ b/apps/comments/tests/unit/Dav/RootCollectionTest.php @@ -45,7 +45,7 @@ class RootCollectionTest extends \Test\TestCase { /** @var \OCP\IUser|\PHPUnit\Framework\MockObject\MockObject */ protected $user; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->user = $this->createMock('\OCP\IUser'); @@ -82,16 +82,18 @@ protected function prepareForInitCollections() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testCreateFile() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->collection->createFile('foo'); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testCreateDirectory() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->collection->createDirectory('foo'); } @@ -102,17 +104,19 @@ public function testGetChild() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetChildInvalid() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $this->prepareForInitCollections(); $this->collection->getChild('robots'); } /** - * @expectedException \Sabre\DAV\Exception\NotAuthenticated */ public function testGetChildNoAuth() { + $this->expectException(\Sabre\DAV\Exception\NotAuthenticated::class); + $this->collection->getChild('files'); } @@ -126,9 +130,10 @@ public function testGetChildren() { } /** - * @expectedException \Sabre\DAV\Exception\NotAuthenticated */ public function testGetChildrenNoAuth() { + $this->expectException(\Sabre\DAV\Exception\NotAuthenticated::class); + $this->collection->getChildren(); } @@ -143,16 +148,18 @@ public function testChildExistsNo() { } /** - * @expectedException \Sabre\DAV\Exception\NotAuthenticated */ public function testChildExistsNoAuth() { + $this->expectException(\Sabre\DAV\Exception\NotAuthenticated::class); + $this->collection->childExists('files'); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDelete() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->collection->delete(); } @@ -161,9 +168,10 @@ public function testGetName() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->collection->setName('foobar'); } diff --git a/apps/dav/tests/unit/Avatars/AvatarHomeTest.php b/apps/dav/tests/unit/Avatars/AvatarHomeTest.php index 202b7293e713..08bfc960b3b1 100644 --- a/apps/dav/tests/unit/Avatars/AvatarHomeTest.php +++ b/apps/dav/tests/unit/Avatars/AvatarHomeTest.php @@ -37,16 +37,17 @@ class AvatarHomeTest extends TestCase { /** @var IAvatarManager | \PHPUnit\Framework\MockObject\MockObject */ private $avatarManager; - public function setUp() { + public function setUp(): void { $this->avatarManager = $this->createMock(IAvatarManager::class); $this->home = new AvatarHome(['uri' => 'principals/users/admin'], $this->avatarManager); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden * @dataProvider providesForbiddenMethods */ public function testForbiddenMethods($method) { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->home->$method(''); } diff --git a/apps/dav/tests/unit/BackgroundJob/CleanPropertiesTest.php b/apps/dav/tests/unit/BackgroundJob/CleanPropertiesTest.php index 121e99351437..39533c73f807 100644 --- a/apps/dav/tests/unit/BackgroundJob/CleanPropertiesTest.php +++ b/apps/dav/tests/unit/BackgroundJob/CleanPropertiesTest.php @@ -44,7 +44,7 @@ class CleanPropertiesTest extends TestCase { /** @var string */ private $username; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); diff --git a/apps/dav/tests/unit/CalDAV/AbstractCalDavBackendTest.php b/apps/dav/tests/unit/CalDAV/AbstractCalDavBackendTest.php index 8a1b52a1c620..136d15763da8 100644 --- a/apps/dav/tests/unit/CalDAV/AbstractCalDavBackendTest.php +++ b/apps/dav/tests/unit/CalDAV/AbstractCalDavBackendTest.php @@ -59,7 +59,7 @@ abstract class AbstractCalDavBackendTest extends TestCase { /** @var ISecureRandom */ private $random; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->principal = $this->getMockBuilder(Principal::class) @@ -83,7 +83,7 @@ public function setUp() { $this->tearDown(); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); if ($this->backend === null) { diff --git a/apps/dav/tests/unit/CalDAV/CalDavBackendTest.php b/apps/dav/tests/unit/CalDAV/CalDavBackendTest.php index c30942d39755..1bca105e6f35 100644 --- a/apps/dav/tests/unit/CalDAV/CalDavBackendTest.php +++ b/apps/dav/tests/unit/CalDAV/CalDavBackendTest.php @@ -385,7 +385,7 @@ public function testCalendarQuery($expectedEventsInResult, $propFilters, $compFi $expectedEventsInResult = \array_map(function ($index) use ($events) { return $events[$index]; }, $expectedEventsInResult); - $this->assertEquals($expectedEventsInResult, $result, '', 0.0, 10, true); + $this->assertEqualsCanonicalizing($expectedEventsInResult, $result); } /** diff --git a/apps/dav/tests/unit/CalDAV/CalendarTest.php b/apps/dav/tests/unit/CalDAV/CalendarTest.php index 1806a6525512..b554f73d9a57 100644 --- a/apps/dav/tests/unit/CalDAV/CalendarTest.php +++ b/apps/dav/tests/unit/CalDAV/CalendarTest.php @@ -36,7 +36,7 @@ class CalendarTest extends TestCase { /** @var IL10N */ private $l10n; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->l10n = $this->getMockBuilder(IL10N::class) ->disableOriginalConstructor()->getMock(); @@ -66,9 +66,10 @@ public function testDelete() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDeleteFromGroup() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + /** @var \PHPUnit\Framework\MockObject\MockObject | CalDavBackend $backend */ $backend = $this->getMockBuilder(CalDavBackend::class)->disableOriginalConstructor()->getMock(); $backend->expects($this->never())->method('updateShares'); diff --git a/apps/dav/tests/unit/CalDAV/PluginTest.php b/apps/dav/tests/unit/CalDAV/PluginTest.php index 8e09e34bff28..07f25746c043 100644 --- a/apps/dav/tests/unit/CalDAV/PluginTest.php +++ b/apps/dav/tests/unit/CalDAV/PluginTest.php @@ -14,7 +14,7 @@ class PluginTest extends TestCase { /** @var Plugin */ private $plugin; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->plugin = new Plugin(); diff --git a/apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php b/apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php index 7df339e9b707..507a5f5860d0 100644 --- a/apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php +++ b/apps/dav/tests/unit/CalDAV/PublicCalendarRootTest.php @@ -61,7 +61,7 @@ class PublicCalendarRootTest extends TestCase { /** @var ISecureRandom */ private $random; - public function setUp() { + public function setUp(): void { parent::setUp(); $db = \OC::$server->getDatabaseConnection(); @@ -81,7 +81,7 @@ public function setUp() { ->disableOriginalConstructor()->getMock(); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); if ($this->backend === null) { @@ -112,9 +112,10 @@ public function testGetChild() { } /** - * @expectedException \Sabre\DAV\Exception\MethodNotAllowed */ public function testGetChildren() { + $this->expectException(\Sabre\DAV\Exception\MethodNotAllowed::class); + $this->createPublicCalendar(); $this->publicCalendarRoot->disableListing = true; diff --git a/apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php b/apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php index bfde545f33bc..bedd8e88c377 100644 --- a/apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php +++ b/apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php @@ -44,7 +44,7 @@ class PluginTest extends TestCase { /** @var IURLGenerator | \PHPUnit\Framework\MockObject\MockObject */ private $urlGenerator; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->getMockBuilder('\OCP\IConfig')-> diff --git a/apps/dav/tests/unit/CardDAV/AddressBookImplTest.php b/apps/dav/tests/unit/CardDAV/AddressBookImplTest.php index fa891d1d76b6..5d80c576cab6 100644 --- a/apps/dav/tests/unit/CardDAV/AddressBookImplTest.php +++ b/apps/dav/tests/unit/CardDAV/AddressBookImplTest.php @@ -52,7 +52,7 @@ class AddressBookImplTest extends TestCase { /** @var VCard | \PHPUnit\Framework\MockObject\MockObject */ private $vCard; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->addressBookInfo = [ @@ -120,7 +120,7 @@ public function testSearch() { )->willReturn('vCard'); $result = $addressBookImpl->search($pattern, $searchProperties, [], 10, 0); - $this->assertInternalType('array', $result); + $this->assertIsArray($result); $this->assertCount(2, $result); } diff --git a/apps/dav/tests/unit/CardDAV/AddressBookTest.php b/apps/dav/tests/unit/CardDAV/AddressBookTest.php index da7ab6b4232d..e89412ea8cb0 100644 --- a/apps/dav/tests/unit/CardDAV/AddressBookTest.php +++ b/apps/dav/tests/unit/CardDAV/AddressBookTest.php @@ -45,9 +45,10 @@ public function testDelete() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDeleteFromGroup() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + /** @var \PHPUnit\Framework\MockObject\MockObject | CardDavBackend $backend */ $backend = $this->getMockBuilder('OCA\DAV\CardDAV\CardDavBackend')->disableOriginalConstructor()->getMock(); $backend->expects($this->never())->method('updateShares'); @@ -64,9 +65,10 @@ public function testDeleteFromGroup() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testPropPatch() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + /** @var \PHPUnit\Framework\MockObject\MockObject | CardDavBackend $backend */ $backend = $this->getMockBuilder('OCA\DAV\CardDAV\CardDavBackend')->disableOriginalConstructor()->getMock(); $calendarInfo = [ diff --git a/apps/dav/tests/unit/CardDAV/BirthdayServiceTest.php b/apps/dav/tests/unit/CardDAV/BirthdayServiceTest.php index f910de092497..b4690e5c87bc 100644 --- a/apps/dav/tests/unit/CardDAV/BirthdayServiceTest.php +++ b/apps/dav/tests/unit/CardDAV/BirthdayServiceTest.php @@ -41,7 +41,7 @@ class BirthdayServiceTest extends TestCase { /** @var GroupPrincipalBackend | \PHPUnit\Framework\MockObject\MockObject */ private $groupPrincipalBackend; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->calDav = $this->getMockBuilder(CalDavBackend::class)->disableOriginalConstructor()->getMock(); diff --git a/apps/dav/tests/unit/CardDAV/CardDavBackendTest.php b/apps/dav/tests/unit/CardDAV/CardDavBackendTest.php index 9dae23bb041a..4b6babc61994 100644 --- a/apps/dav/tests/unit/CardDAV/CardDavBackendTest.php +++ b/apps/dav/tests/unit/CardDAV/CardDavBackendTest.php @@ -68,7 +68,7 @@ class CardDavBackendTest extends TestCase { const UNIT_TEST_USER1 = 'principals/users/carddav-unit-test1'; const UNIT_TEST_GROUP = 'principals/groups/carddav-unit-test-group'; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->principal = $this->getMockBuilder(Principal::class) @@ -98,7 +98,7 @@ public function setUp() { $this->tearDown(); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); if ($this->backend === null) { @@ -472,9 +472,10 @@ public function testGetCardId() { } /** - * @expectedException InvalidArgumentException */ public function testGetCardIdFailed() { + $this->expectException(\InvalidArgumentException::class); + static::invokePrivate($this->backend, 'getCardId', [1, 'uri']); } @@ -598,9 +599,10 @@ public function testGetCardUri() { } /** - * @expectedException InvalidArgumentException */ public function testGetCardUriFailed() { + $this->expectException(\InvalidArgumentException::class); + $this->backend->getCardUri(1); } diff --git a/apps/dav/tests/unit/CardDAV/ImageExportPluginTest.php b/apps/dav/tests/unit/CardDAV/ImageExportPluginTest.php index ebc5f94abb5e..f6e11b92dd81 100644 --- a/apps/dav/tests/unit/CardDAV/ImageExportPluginTest.php +++ b/apps/dav/tests/unit/CardDAV/ImageExportPluginTest.php @@ -46,7 +46,7 @@ class ImageExportPluginTest extends TestCase { /** @var ILogger | \PHPUnit\Framework\MockObject\MockObject */ private $logger; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->getMockBuilder('Sabre\HTTP\RequestInterface')->getMock(); diff --git a/apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php b/apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php index 720522952c02..20a11df8ed8e 100644 --- a/apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php +++ b/apps/dav/tests/unit/CardDAV/Sharing/PluginTest.php @@ -41,7 +41,7 @@ class PluginTest extends TestCase { /** @var IShareable | \PHPUnit\Framework\MockObject\MockObject */ private $book; - public function setUp() { + public function setUp(): void { parent::setUp(); /** @var Auth | \PHPUnit\Framework\MockObject\MockObject $authBackend */ diff --git a/apps/dav/tests/unit/Command/CleanupChunksTest.php b/apps/dav/tests/unit/Command/CleanupChunksTest.php index 225ebcef82c1..cc852a888c55 100644 --- a/apps/dav/tests/unit/Command/CleanupChunksTest.php +++ b/apps/dav/tests/unit/Command/CleanupChunksTest.php @@ -42,7 +42,7 @@ class CleanupChunksTest extends TestCase { /** @var IUser */ private $user; - public function setUp() { + public function setUp(): void { parent::setUp(); $command = new CleanupChunks(\OC::$server->getUserManager()); @@ -59,7 +59,10 @@ public function testCommandInput($inputDays, $expectedDays) { 'age-in-days' => $inputDays ]); $output = $this->commandTester->getDisplay(); - $this->assertContains("Cleaning chunks older than $expectedDays days", $output); + $this->assertStringContainsString( + "Cleaning chunks older than $expectedDays days", + $output + ); } public function testCommand() { @@ -77,8 +80,8 @@ public function testCommand() { $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains("Cleaning chunks older than 2 days", $output); - $this->assertContains("Cleaning chunks for $userId", $output); + $this->assertStringContainsString("Cleaning chunks older than 2 days", $output); + $this->assertStringContainsString("Cleaning chunks for $userId", $output); $this->assertFalse($view->file_exists($uploadId)); } diff --git a/apps/dav/tests/unit/Connector/PublicAuthTest.php b/apps/dav/tests/unit/Connector/PublicAuthTest.php index 5040b05f0c66..e26dba5c6509 100644 --- a/apps/dav/tests/unit/Connector/PublicAuthTest.php +++ b/apps/dav/tests/unit/Connector/PublicAuthTest.php @@ -49,7 +49,7 @@ class PublicAuthTest extends \Test\TestCase { /** @var string */ private $oldUser; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->session = $this->createMock('\OCP\ISession'); @@ -66,7 +66,7 @@ protected function setUp() { $this->oldUser = \OC_User::getUser(); } - protected function tearDown() { + protected function tearDown(): void { \OC_User::setIncognitoMode(false); // Set old user diff --git a/apps/dav/tests/unit/Connector/Sabre/AuthTest.php b/apps/dav/tests/unit/Connector/Sabre/AuthTest.php index 0b186f2f0096..4679682aacfd 100644 --- a/apps/dav/tests/unit/Connector/Sabre/AuthTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/AuthTest.php @@ -62,7 +62,7 @@ class AuthTest extends TestCase { /** @var AccountModuleManager | MockObject */ private $accountModuleManager; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->session = $this->createMock(ISession::class); $this->userSession = $this->createMock(Session::class); @@ -228,9 +228,10 @@ public function testValidateUserPassWithInvalidPassword() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\PasswordLoginForbidden */ public function testValidateUserPassWithPasswordLoginForbidden() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\PasswordLoginForbidden::class); + $this->userSession ->expects($this->once()) ->method('isLoggedIn') @@ -332,10 +333,11 @@ public function testAuthenticateAlreadyLoggedInWithoutCsrfTokenAndCorrectlyDavAu } /** - * @expectedException \Sabre\DAV\Exception\NotAuthenticated - * @expectedExceptionMessage 2FA challenge not passed. */ public function testAuthenticateAlreadyLoggedInWithoutTwoFactorChallengePassed() { + $this->expectException(\Sabre\DAV\Exception\NotAuthenticated::class); + $this->expectExceptionMessage('2FA challenge not passed.'); + /** @var RequestInterface | MockObject $request */ $request = $this->getMockBuilder(RequestInterface::class) ->disableOriginalConstructor() @@ -493,9 +495,10 @@ public function testAuthenticateAlreadyLoggedInWithCsrfTokenForGet() { } /** - * @expectedException \Sabre\DAV\Exception\NotAuthenticated */ public function testAutenticateWithLoggedInUserButLoginExceptionThrown() { + $this->expectException(\Sabre\DAV\Exception\NotAuthenticated::class); + /** @var RequestInterface | MockObject $request */ $request = $this->getMockBuilder(RequestInterface::class) ->disableOriginalConstructor() diff --git a/apps/dav/tests/unit/Connector/Sabre/BlockLegacyClientPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/BlockLegacyClientPluginTest.php index 1051867640d0..1e7f9932703b 100644 --- a/apps/dav/tests/unit/Connector/Sabre/BlockLegacyClientPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/BlockLegacyClientPluginTest.php @@ -39,7 +39,7 @@ class BlockLegacyClientPluginTest extends TestCase { /** @var BlockLegacyClientPlugin */ private $blockLegacyClientVersionPlugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->createMock('\OCP\IConfig'); @@ -62,10 +62,11 @@ public function oldDesktopClientProvider() { /** * @dataProvider oldDesktopClientProvider * @param string $userAgent - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Unsupported client version. */ public function testBeforeHandlerException($userAgent) { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Unsupported client version.'); + /** @var \Sabre\HTTP\RequestInterface | PHPUnit\Framework\MockObject\MockObject $request */ $request = $this->createMock('\Sabre\HTTP\RequestInterface'); $request diff --git a/apps/dav/tests/unit/Connector/Sabre/CommentsPropertiesPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/CommentsPropertiesPluginTest.php index 8e20020030b1..ee8d65b19d49 100644 --- a/apps/dav/tests/unit/Connector/Sabre/CommentsPropertiesPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/CommentsPropertiesPluginTest.php @@ -34,7 +34,7 @@ class CommentsPropertiesPluginTest extends \Test\TestCase { protected $server; protected $userFolder; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->commentsManager = $this->createMock('\OCP\Comments\ICommentsManager'); diff --git a/apps/dav/tests/unit/Connector/Sabre/CopyEtagHeaderPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/CopyEtagHeaderPluginTest.php index 6728c802c564..b9bb2f595004 100644 --- a/apps/dav/tests/unit/Connector/Sabre/CopyEtagHeaderPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/CopyEtagHeaderPluginTest.php @@ -42,7 +42,7 @@ class CopyEtagHeaderPluginTest extends TestCase { /** @var Server */ private $server; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = new \Sabre\DAV\Server(); $this->plugin = new CopyEtagHeaderPlugin(); diff --git a/apps/dav/tests/unit/Connector/Sabre/CorsPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/CorsPluginTest.php index fd22d7931be6..5af1bb31fb6a 100644 --- a/apps/dav/tests/unit/Connector/Sabre/CorsPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/CorsPluginTest.php @@ -52,7 +52,7 @@ class CorsPluginTest extends TestCase { */ private $config; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = new Server(); @@ -79,7 +79,7 @@ public function setUp() { $this->server->addPlugin($extraMethodPlugin); } - public function tearDown() { + public function tearDown(): void { $this->restoreService('AllConfig'); } diff --git a/apps/dav/tests/unit/Connector/Sabre/DirectoryTest.php b/apps/dav/tests/unit/Connector/Sabre/DirectoryTest.php index 1459e6f6403a..6900f4a5ad58 100644 --- a/apps/dav/tests/unit/Connector/Sabre/DirectoryTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/DirectoryTest.php @@ -75,7 +75,7 @@ class DirectoryTest extends \Test\TestCase { /** @var \OC\Files\FileInfo | \PHPUnit\Framework\MockObject\MockObject */ private $info; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->view = $this->createMock('OC\Files\View', [], [], '', false); @@ -115,9 +115,10 @@ public function testChildExists($exists) { } /** - * @expectedException \Sabre\DAV\Exception\ServiceUnavailable */ public function testChildExistsStorageNotAvailable() { + $this->expectException(\Sabre\DAV\Exception\ServiceUnavailable::class); + $this->view->method('file_exists') ->will($this->throwException(new StorageNotAvailableException())); $dir = $this->getDir(); @@ -125,9 +126,10 @@ public function testChildExistsStorageNotAvailable() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDeleteRootFolderFails() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->info->expects($this->any()) ->method('isDeletable') ->will($this->returnValue(true)); @@ -138,9 +140,10 @@ public function testDeleteRootFolderFails() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\Forbidden */ public function testDeleteForbidden() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + // deletion allowed $this->info->expects($this->once()) ->method('isDeletable') @@ -176,9 +179,10 @@ public function testDeleteFolderWhenAllowed() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDeleteFolderFailsWhenNotAllowed() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->info->expects($this->once()) ->method('isDeletable') ->will($this->returnValue(false)); @@ -188,9 +192,10 @@ public function testDeleteFolderFailsWhenNotAllowed() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDeleteFolderThrowsWhenDeletionFailed() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + // deletion allowed $this->info->expects($this->once()) ->method('isDeletable') @@ -207,9 +212,10 @@ public function testDeleteFolderThrowsWhenDeletionFailed() { } /** - * @expectedException \Sabre\DAV\Exception\ServiceUnavailable */ public function testDeleteFolderThrowsWhenStorageNotAvailable() { + $this->expectException(\Sabre\DAV\Exception\ServiceUnavailable::class); + // deletion allowed $this->info->expects($this->once()) ->method('isDeletable') @@ -265,9 +271,10 @@ public function testGetChildren() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testGetChildrenNoPermission() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $info = $this->getMockBuilder('OC\Files\FileInfo') ->disableOriginalConstructor() ->getMock(); @@ -280,9 +287,10 @@ public function testGetChildrenNoPermission() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetChildNoPermission() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $info = $this->getMockBuilder('OC\Files\FileInfo') ->disableOriginalConstructor() ->getMock(); @@ -295,9 +303,10 @@ public function testGetChildNoPermission() { } /** - * @expectedException \Sabre\DAV\Exception\ServiceUnavailable */ public function testGetChildThrowStorageNotAvailableException() { + $this->expectException(\Sabre\DAV\Exception\ServiceUnavailable::class); + $this->view->expects($this->once()) ->method('getFileInfo') ->willThrowException(new StorageNotAvailableException()); @@ -307,9 +316,10 @@ public function testGetChildThrowStorageNotAvailableException() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\InvalidPath */ public function testGetChildThrowInvalidPath() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\InvalidPath::class); + $this->view->expects($this->once()) ->method('verifyPath') ->willThrowException(new \OCP\Files\InvalidPathException()); @@ -385,9 +395,10 @@ public function testGetQuotaInfoSpecific() { /** * @dataProvider moveFailedProvider - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testMoveFailed($source, $destination, $updatables, $deletables) { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->moveTest($source, $destination, $updatables, $deletables); } @@ -401,9 +412,10 @@ public function testMoveSuccess($source, $destination, $updatables, $deletables) /** * @dataProvider moveFailedInvalidCharsProvider - * @expectedException \OCA\DAV\Connector\Sabre\Exception\InvalidPath */ public function testMoveFailedInvalidChars($source, $destination, $updatables, $deletables) { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\InvalidPath::class); + $this->moveTest($source, $destination, $updatables, $deletables); } @@ -455,10 +467,11 @@ private function moveTest($source, $destination, $updatables, $deletables) { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Could not copy directory b, target exists */ public function testFailingMove() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Could not copy directory b, target exists'); + $source = 'a/b'; $destination = 'c/b'; $updatables = ['a' => true, 'a/b' => true, 'b' => true, 'c/b' => false]; @@ -484,10 +497,11 @@ public function testFailingMove() { /** * A test to throw ExcludeForbiddenException * - * @expectedException \OCP\Files\FileContentNotAllowedException - * @expectedExceptionMessage The message already logged */ public function testFailCreateFile() { + $this->expectException(\OCP\Files\FileContentNotAllowedException::class); + $this->expectExceptionMessage('The message already logged'); + //$this->invokePrivate(); $previous = new FileContentNotAllowedException('The message already logged', false); $this->view->expects($this->any()) @@ -498,9 +512,10 @@ public function testFailCreateFile() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testCreateFileForbidden() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->view->expects($this->any()) ->method('isCreatable') ->willThrowException(new \Sabre\DAV\Exception\Forbidden()); @@ -509,9 +524,10 @@ public function testCreateFileForbidden() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\Forbidden */ public function testSetNameRenameOperationFailed() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + $storage = $this->createMock(IStorage::class); $storage->method('getId')->will($this->returnValue('home::someuser')); diff --git a/apps/dav/tests/unit/Connector/Sabre/DummyGetResponsePluginTest.php b/apps/dav/tests/unit/Connector/Sabre/DummyGetResponsePluginTest.php index df5403bc595d..bbddea9db928 100644 --- a/apps/dav/tests/unit/Connector/Sabre/DummyGetResponsePluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/DummyGetResponsePluginTest.php @@ -35,7 +35,7 @@ class DummyGetResponsePluginTest extends TestCase { /** @var DummyGetResponsePlugin */ private $dummyGetResponsePlugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->dummyGetResponsePlugin = new DummyGetResponsePlugin(); diff --git a/apps/dav/tests/unit/Connector/Sabre/FileTest.php b/apps/dav/tests/unit/Connector/Sabre/FileTest.php index f5c657a736b2..a98f6d2e0c75 100644 --- a/apps/dav/tests/unit/Connector/Sabre/FileTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/FileTest.php @@ -69,7 +69,7 @@ class FileTest extends TestCase { /** @var IConfig | \PHPUnit\Framework\MockObject\MockObject */ protected $config; - public function setUp() { + public function setUp(): void { parent::setUp(); unset($_SERVER['HTTP_OC_CHUNKED'], $_SERVER['CONTENT_LENGTH'], $_SERVER['REQUEST_METHOD']); @@ -84,7 +84,7 @@ public function setUp() { $this->config = $this->getMockBuilder('\OCP\IConfig')->getMock(); } - public function tearDown() { + public function tearDown(): void { $userManager = \OC::$server->getUserManager(); if ($userManager->userExists($this->user)) { $userManager->get($this->user)->delete(); @@ -236,11 +236,12 @@ function ($path) use ($storage) { * Test that FileContentNotAllowedException properly mapped to * ForbiddenException * - * @expectedException \OCA\DAV\Connector\Sabre\Exception\Forbidden * * @return void */ public function testFileContentNotAllowedConvertedToForbidden() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + $storage = $this->getMockBuilder(Local::class) ->setMethods(['fopen']) ->setConstructorArgs( @@ -478,9 +479,10 @@ public function testPutSingleFile() { } /** - * @expectedException \Sabre\DAV\Exception\BadRequest */ public function testPutSingleFileWrongChecksum() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $request = new \OC\AppFramework\Http\Request([ 'server' => [ 'HTTP_OC_CHECKSUM' => '00000000000000', @@ -491,9 +493,10 @@ public function testPutSingleFileWrongChecksum() { } /** - * @expectedException \Sabre\DAV\Exception\BadRequest */ public function testChunkedPutFileWrongChecksum() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $request = new \OC\AppFramework\Http\Request([ 'server' => [ 'HTTP_OC_CHECKSUM' => '000000000000', @@ -1018,9 +1021,10 @@ public function testSimplePutInvalidChars() { /** * Test setting name with setName() with invalid chars * - * @expectedException \OCA\DAV\Connector\Sabre\Exception\InvalidPath */ public function testSetNameInvalidChars() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\InvalidPath::class); + // setup $view = $this->getMockBuilder(View::class) ->setMethods(['getRelativePath']) @@ -1038,9 +1042,10 @@ public function testSetNameInvalidChars() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\Forbidden */ public function testSetNameRenameOperationFailed() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + $view = $this->createMock(View::class); $view->method('verifyPath')->willReturn(true); $view->method('getRelativePath')->will($this->returnArgument(0)); @@ -1120,9 +1125,10 @@ public function testDeleteWhenAllowed() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDeleteThrowsWhenDeletionNotAllowed() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + // setup $view = $this->createMock(View::class); @@ -1137,9 +1143,10 @@ public function testDeleteThrowsWhenDeletionNotAllowed() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testDeleteThrowsWhenDeletionFailed() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + // setup $view = $this->createMock(View::class); @@ -1159,9 +1166,10 @@ public function testDeleteThrowsWhenDeletionFailed() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\Forbidden */ public function testDeleteThrowsWhenDeletionThrows() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + // setup $view = $this->createMock(View::class); @@ -1396,9 +1404,10 @@ private function getFileInfos($path = '', View $userView = null) { } /** - * @expectedException \Sabre\DAV\Exception\ServiceUnavailable */ public function testGetFopenFails() { + $this->expectException(\Sabre\DAV\Exception\ServiceUnavailable::class); + $view = $this->getMockBuilder(View::class) ->setMethods(['fopen', 'file_exists']) ->getMock(); @@ -1419,9 +1428,10 @@ public function testGetFopenFails() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\Forbidden */ public function testGetFopenThrows() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + $view = $this->getMockBuilder(View::class) ->setMethods(['fopen', 'file_exists']) ->getMock(); @@ -1442,10 +1452,11 @@ public function testGetFopenThrows() { } /** - * @expectedException \Sabre\Dav\Exception\Forbidden - * @expectedExceptionMessage Encryption not ready */ public function testFopenForbiddenExceptionEncryption() { + $this->expectException(\Sabre\Dav\Exception\Forbidden::class); + $this->expectExceptionMessage('Encryption not ready'); + $view = $this->getMockBuilder(View::class) ->setMethods(['fopen', 'file_exists']) ->getMock(); @@ -1466,9 +1477,10 @@ public function testFopenForbiddenExceptionEncryption() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetThrowsIfNoPermission() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $view = $this->getMockBuilder(View::class) ->setMethods(['fopen']) ->getMock(); @@ -1485,9 +1497,10 @@ public function testGetThrowsIfNoPermission() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetThrowsIfFileNotExists() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $view = $this->getMockBuilder(View::class) ->setMethods(['fopen', 'file_exists']) ->getMock(); @@ -1507,9 +1520,10 @@ public function testGetThrowsIfFileNotExists() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetThrowsIfNoPermissionsAndFileNotExists() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $view = $this->getMockBuilder(View::class) ->setMethods(['fopen', 'file_exists']) ->getMock(); diff --git a/apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php index a668de333575..c9fc122c7185 100644 --- a/apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php @@ -87,7 +87,7 @@ class FilesPluginTest extends TestCase { */ private $request; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = $this->getMockBuilder(Server::class) ->disableOriginalConstructor() @@ -342,9 +342,10 @@ public function testGetPropertiesForRootDirectory() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetPropertiesWhenNoPermission() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + /** @var Directory | \PHPUnit\Framework\MockObject\MockObject $node */ $node = $this->getMockBuilder(Directory::class) ->disableOriginalConstructor() @@ -446,10 +447,11 @@ public function testUpdatePropsForbidden() { * FolderA is an incoming shared folder and there are no delete permissions. * Thus moving /FolderA/test.txt to /test.txt should fail already on that check * - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage FolderA/test.txt cannot be deleted */ public function testMoveSrcNotDeletable() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('FolderA/test.txt cannot be deleted'); + $fileInfoFolderATestTXT = $this->getMockBuilder(FileInfo::class) ->disableOriginalConstructor() ->getMock(); @@ -488,10 +490,11 @@ public function testMoveSrcDeletable() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound - * @expectedExceptionMessage FolderA/test.txt does not exist */ public function testMoveSrcNotExist() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $this->expectExceptionMessage('FolderA/test.txt does not exist'); + $node = $this->createMock(Node::class); $node->expects($this->once()) ->method('getFileInfo') diff --git a/apps/dav/tests/unit/Connector/Sabre/FilesReportPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/FilesReportPluginTest.php index 1271ceaf6a9e..f727fd28d1e8 100644 --- a/apps/dav/tests/unit/Connector/Sabre/FilesReportPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/FilesReportPluginTest.php @@ -66,7 +66,7 @@ class FilesReportPluginTest extends \Test\TestCase { /** @var Folder|\PHPUnit\Framework\MockObject\MockObject **/ private $userFolder; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') ->disableOriginalConstructor() @@ -594,9 +594,10 @@ public function testProcessFilterRulesInvisibleTagAsAdmin() { } /** - * @expectedException \OCP\SystemTag\TagNotFoundException */ public function testProcessFilterRulesInvisibleTagAsUser() { + $this->expectException(\OCP\SystemTag\TagNotFoundException::class); + $this->groupManager->expects($this->any()) ->method('isAdmin') ->will($this->returnValue(false)); diff --git a/apps/dav/tests/unit/Connector/Sabre/FilesSearchReportPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/FilesSearchReportPluginTest.php index bdeb571d34ab..a51796c112a1 100644 --- a/apps/dav/tests/unit/Connector/Sabre/FilesSearchReportPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/FilesSearchReportPluginTest.php @@ -45,7 +45,7 @@ class FilesSearchReportPluginTest extends \Test\TestCase { /** @var FilesSearchReportPlugin|\PHPUnit\Framework\MockObject\MockObject */ private $plugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->tree = $this->getMockBuilder(Tree::class) @@ -107,9 +107,10 @@ public function testOnReportWrongReportName() { } /** - * @expectedException \Sabre\DAV\Exception\NotImplemented */ public function testOnReportNotRoot() { + $this->expectException(\Sabre\DAV\Exception\NotImplemented::class); + $base = '/remote.php/dav/files/user'; $nodePath = '/totally/unrelated/13'; $path = "{$base}{$nodePath}"; @@ -136,9 +137,10 @@ public function onReportNoSearchPatternProvider() { /** * @dataProvider onReportNoSearchPatternProvider - * @expectedException \Sabre\DAV\Exception\BadRequest */ public function testOnReportNoSearchPattern($properties, $searchInfo) { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $base = '/remote.php/dav/files/user'; $nodePath = '/'; $path = "{$base}{$nodePath}"; diff --git a/apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php b/apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php index 9efaf5edc0ad..48fc418794ed 100644 --- a/apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/MaintenancePluginTest.php @@ -37,7 +37,7 @@ class MaintenancePluginTest extends TestCase { /** @var MaintenancePlugin */ private $maintenancePlugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->createMock('\OCP\IConfig'); @@ -45,10 +45,11 @@ public function setUp() { } /** - * @expectedException \Sabre\DAV\Exception\ServiceUnavailable - * @expectedExceptionMessage System in single user mode. */ public function testSingleUserMode() { + $this->expectException(\Sabre\DAV\Exception\ServiceUnavailable::class); + $this->expectExceptionMessage('System in single user mode.'); + $this->config ->expects($this->once()) ->method('getSystemValue') @@ -59,10 +60,11 @@ public function testSingleUserMode() { } /** - * @expectedException \Sabre\DAV\Exception\ServiceUnavailable - * @expectedExceptionMessage System in single user mode. */ public function testMaintenanceMode() { + $this->expectException(\Sabre\DAV\Exception\ServiceUnavailable::class); + $this->expectExceptionMessage('System in single user mode.'); + $this->config ->expects($this->exactly(1)) ->method('getSystemValue') diff --git a/apps/dav/tests/unit/Connector/Sabre/ObjectTreeTest.php b/apps/dav/tests/unit/Connector/Sabre/ObjectTreeTest.php index 671893acee3e..392dc8077176 100644 --- a/apps/dav/tests/unit/Connector/Sabre/ObjectTreeTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/ObjectTreeTest.php @@ -91,9 +91,10 @@ public function testCopy($sourcePath, $targetPath, $targetParent) { /** * @dataProvider copyDataProvider - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testCopyFailNotCreatable($sourcePath, $targetPath, $targetParent) { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $view = $this->createMock(View::class); $view->expects($this->once()) ->method('verifyPath') @@ -244,9 +245,10 @@ public function nodeForPathProvider() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\InvalidPath */ public function testGetNodeForPathInvalidPath() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\InvalidPath::class); + $path = '/foo\bar'; $storage = new Temporary([]); diff --git a/apps/dav/tests/unit/Connector/Sabre/PrincipalTest.php b/apps/dav/tests/unit/Connector/Sabre/PrincipalTest.php index 77aca9282ef0..062f316324ec 100644 --- a/apps/dav/tests/unit/Connector/Sabre/PrincipalTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/PrincipalTest.php @@ -37,7 +37,7 @@ class PrincipalTest extends TestCase { /** @var IGroupManager | \PHPUnit\Framework\MockObject\MockObject */ private $groupManager; - public function setUp() { + public function setUp(): void { $this->userManager = $this->getMockBuilder('\OCP\IUserManager') ->disableOriginalConstructor()->getMock(); $this->groupManager = $this->getMockBuilder('\OCP\IGroupManager') @@ -187,10 +187,11 @@ public function testGetGroupMemberSet() { } /** - * @expectedException \Sabre\DAV\Exception - * @expectedExceptionMessage Principal not found */ public function testGetGroupMemberSetEmpty() { + $this->expectException(\Sabre\DAV\Exception::class); + $this->expectExceptionMessage('Principal not found'); + $this->userManager ->expects($this->once()) ->method('get') @@ -228,10 +229,11 @@ public function testGetGroupMembership() { } /** - * @expectedException \Sabre\DAV\Exception - * @expectedExceptionMessage Principal not found */ public function testGetGroupMembershipEmpty() { + $this->expectException(\Sabre\DAV\Exception::class); + $this->expectExceptionMessage('Principal not found'); + $this->userManager ->expects($this->once()) ->method('get') @@ -242,10 +244,11 @@ public function testGetGroupMembershipEmpty() { } /** - * @expectedException \Sabre\DAV\Exception - * @expectedExceptionMessage Setting members of the group is not supported yet */ public function testSetGroupMembership() { + $this->expectException(\Sabre\DAV\Exception::class); + $this->expectExceptionMessage('Setting members of the group is not supported yet'); + $this->connector->setGroupMemberSet('principals/users/foo', ['foo']); } diff --git a/apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php index 380422063ad6..199175b96d19 100644 --- a/apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php @@ -81,10 +81,11 @@ public function testCheckQuota($quota, $headers) { } /** - * @expectedException \Sabre\DAV\Exception\InsufficientStorage * @dataProvider quotaExceededProvider */ public function testCheckExceededQuota($quota, $headers) { + $this->expectException(\Sabre\DAV\Exception\InsufficientStorage::class); + $this->init($quota); $this->plugin->expects($this->never()) ->method('getFileChunking'); @@ -212,9 +213,10 @@ public function quotaChunkedFailProvider() { /** * @dataProvider quotaChunkedFailProvider - * @expectedException \Sabre\DAV\Exception\InsufficientStorage */ public function testCheckQuotaChunkedFail($quota, $chunkTotalSize, $headers) { + $this->expectException(\Sabre\DAV\Exception\InsufficientStorage::class); + $this->init($quota, 'sub/test.txt'); $mockChunking = $this->getMockBuilder(\OC_FileChunking::class) diff --git a/apps/dav/tests/unit/Connector/Sabre/RequestTest/DownloadTest.php b/apps/dav/tests/unit/Connector/Sabre/RequestTest/DownloadTest.php index b82d991a0b9b..c618712e36fe 100644 --- a/apps/dav/tests/unit/Connector/Sabre/RequestTest/DownloadTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/RequestTest/DownloadTest.php @@ -46,9 +46,10 @@ public function testDownload() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\FileLocked */ public function testDownloadWriteLocked() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\FileLocked::class); + $user = $this->getUniqueID(); $view = $this->setupUser($user, 'pass'); diff --git a/apps/dav/tests/unit/Connector/Sabre/RequestTest/PartFileInRootUploadTest.php b/apps/dav/tests/unit/Connector/Sabre/RequestTest/PartFileInRootUploadTest.php index 556b55558215..24400afd69cb 100644 --- a/apps/dav/tests/unit/Connector/Sabre/RequestTest/PartFileInRootUploadTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/RequestTest/PartFileInRootUploadTest.php @@ -33,18 +33,18 @@ class PartFileInRootUploadTest extends UploadTest { protected $original; - protected function setUp() { + protected function setUp(): void { $config = \OC::$server->getConfig(); $this->original = $config->getSystemValue('part_file_in_storage', null); $config->setSystemValue('part_file_in_storage', false); parent::setUp(); } - protected function tearDown() { + protected function tearDown(): void { if ($this->original !== null) { $config = \OC::$server->getConfig(); $this->original = $config->setSystemValue('part_file_in_storage', $this->original); } - return parent::tearDown(); + parent::tearDown(); } } diff --git a/apps/dav/tests/unit/Connector/Sabre/RequestTest/RequestTest.php b/apps/dav/tests/unit/Connector/Sabre/RequestTest/RequestTest.php index 987525050f2a..bbcef1089ec3 100644 --- a/apps/dav/tests/unit/Connector/Sabre/RequestTest/RequestTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/RequestTest/RequestTest.php @@ -50,7 +50,7 @@ protected function getStream($string) { return $stream; } - protected function setUp() { + protected function setUp(): void { parent::setUp(); unset($_SERVER['HTTP_OC_CHUNKED']); diff --git a/apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php b/apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php index 1d9f34b3400e..7dbba1b6c569 100644 --- a/apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php @@ -67,9 +67,10 @@ public function testUploadOverWrite() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\FileLocked */ public function testUploadOverWriteReadLocked() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\FileLocked::class); + $user = $this->getUniqueID(); $view = $this->setupUser($user, 'pass'); @@ -81,9 +82,10 @@ public function testUploadOverWriteReadLocked() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\FileLocked */ public function testUploadOverWriteWriteLocked() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\FileLocked::class); + $user = $this->getUniqueID(); $view = $this->setupUser($user, 'pass'); $this->loginAsUser($user); @@ -161,9 +163,10 @@ public function testChunkedUploadOutOfOrder() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\FileLocked */ public function testChunkedUploadOutOfOrderReadLocked() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\FileLocked::class); + $user = $this->getUniqueID(); $view = $this->setupUser($user, 'pass'); @@ -186,9 +189,10 @@ public function testChunkedUploadOutOfOrderReadLocked() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\FileLocked */ public function testChunkedUploadOutOfOrderWriteLocked() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\FileLocked::class); + $user = $this->getUniqueID(); $view = $this->setupUser($user, 'pass'); diff --git a/apps/dav/tests/unit/Connector/Sabre/SharesPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/SharesPluginTest.php index 8e5bfc301d24..82dee09b59cc 100644 --- a/apps/dav/tests/unit/Connector/Sabre/SharesPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/SharesPluginTest.php @@ -52,7 +52,7 @@ class SharesPluginTest extends \Test\TestCase { */ private $plugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = new \Sabre\DAV\Server(); $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') diff --git a/apps/dav/tests/unit/Connector/Sabre/TagsPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/TagsPluginTest.php index 01d7319d5295..d2b3d8f46726 100644 --- a/apps/dav/tests/unit/Connector/Sabre/TagsPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/TagsPluginTest.php @@ -58,7 +58,7 @@ class TagsPluginTest extends \Test\TestCase { */ private $plugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = new \Sabre\DAV\Server(); $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') diff --git a/apps/dav/tests/unit/Connector/Sabre/ValidateRequestPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/ValidateRequestPluginTest.php index 2fc5f6333d23..d3703e8a1328 100644 --- a/apps/dav/tests/unit/Connector/Sabre/ValidateRequestPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/ValidateRequestPluginTest.php @@ -36,17 +36,18 @@ class ValidateRequestPluginTest extends TestCase { /** @var ValidateRequestPlugin */ private $plugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = new \Sabre\DAV\Server(); } /** - * @expectedException \Sabre\DAV\Exception\ServiceUnavailable - * @expectedExceptionMessage Specified header (HTTP_OC_CHUNKED/OC-Chunked header) is allowed only in webdav endpoint */ public function testOldChunkingInNewEndpoint1() { + $this->expectException(\Sabre\DAV\Exception\ServiceUnavailable::class); + $this->expectExceptionMessage('Specified header (HTTP_OC_CHUNKED/OC-Chunked header) is allowed only in webdav endpoint'); + $headers['HTTP_OC_CHUNKED'] = 1; $this->plugin = new ValidateRequestPlugin('dav'); @@ -57,10 +58,11 @@ public function testOldChunkingInNewEndpoint1() { } /** - * @expectedException \Sabre\DAV\Exception\ServiceUnavailable - * @expectedExceptionMessage Specified header (HTTP_OC_CHUNKED/OC-Chunked header) is allowed only in webdav endpoint */ public function testOldChunkingInNewEndpoint2() { + $this->expectException(\Sabre\DAV\Exception\ServiceUnavailable::class); + $this->expectExceptionMessage('Specified header (HTTP_OC_CHUNKED/OC-Chunked header) is allowed only in webdav endpoint'); + $headers['OC-Chunked'] = 1; $this->plugin = new ValidateRequestPlugin('dav'); diff --git a/apps/dav/tests/unit/DAV/CopyPluginTest.php b/apps/dav/tests/unit/DAV/CopyPluginTest.php index baf62c9ff29d..f5fcb2b4818d 100644 --- a/apps/dav/tests/unit/DAV/CopyPluginTest.php +++ b/apps/dav/tests/unit/DAV/CopyPluginTest.php @@ -48,7 +48,7 @@ class CopyPluginTest extends TestCase { /** @var ResponseInterface | \PHPUnit\Framework\MockObject\MockObject */ private $response; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->plugin = new CopyPlugin(); @@ -119,10 +119,11 @@ public function testCopyPluginReturnFalse() { } /** - * @expectedException OCA\DAV\Connector\Sabre\Exception\Forbidden - * @expectedExceptionMessage Test exception */ public function testCopyPluginRethrowForbidden() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + $this->expectExceptionMessage('Test exception'); + $destinationNode = $this->createMock(File::class); $sourceNode = $this->createMock([ICopySource::class, IFile::class]); diff --git a/apps/dav/tests/unit/DAV/FileCustomPropertiesBackendTest.php b/apps/dav/tests/unit/DAV/FileCustomPropertiesBackendTest.php index 4467499f5295..693a47253964 100644 --- a/apps/dav/tests/unit/DAV/FileCustomPropertiesBackendTest.php +++ b/apps/dav/tests/unit/DAV/FileCustomPropertiesBackendTest.php @@ -79,7 +79,7 @@ class FileCustomPropertiesBackendTest extends \Test\TestCase { /** @var int */ private $maxId; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = new \Sabre\DAV\Server(); $this->tree = $this->getMockBuilder(Tree::class) @@ -112,7 +112,7 @@ public function setUp() { ->execute()->fetchColumn(); } - public function tearDown() { + public function tearDown(): void { $connection = \OC::$server->getDatabaseConnection(); $deleteStatement = $connection->prepare( 'DELETE FROM `*PREFIX*properties`' . diff --git a/apps/dav/tests/unit/DAV/GroupPrincipalTest.php b/apps/dav/tests/unit/DAV/GroupPrincipalTest.php index e8efede071d3..86b83c771a2e 100644 --- a/apps/dav/tests/unit/DAV/GroupPrincipalTest.php +++ b/apps/dav/tests/unit/DAV/GroupPrincipalTest.php @@ -36,7 +36,7 @@ class GroupPrincipalTest extends \Test\TestCase { /** @var GroupPrincipalBackend */ private $connector; - public function setUp() { + public function setUp(): void { $this->groupManager = $this->getMockBuilder(IGroupManager::class) ->disableOriginalConstructor()->getMock(); @@ -137,10 +137,11 @@ public function testGetGroupMembership() { } /** - * @expectedException \Sabre\DAV\Exception - * @expectedExceptionMessage Setting members of the group is not supported yet */ public function testSetGroupMembership() { + $this->expectException(\Sabre\DAV\Exception::class); + $this->expectExceptionMessage('Setting members of the group is not supported yet'); + $this->connector->setGroupMemberSet('principals/groups/foo', ['foo']); } diff --git a/apps/dav/tests/unit/DAV/HookManagerTest.php b/apps/dav/tests/unit/DAV/HookManagerTest.php index d55bac0a5457..a65aa9b852ec 100644 --- a/apps/dav/tests/unit/DAV/HookManagerTest.php +++ b/apps/dav/tests/unit/DAV/HookManagerTest.php @@ -38,7 +38,7 @@ class HookManagerTest extends TestCase { /** @var L10N */ private $l10n; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->l10n = $this->getMockBuilder('OC\L10N\L10N') diff --git a/apps/dav/tests/unit/DAV/LazyOpsPluginTest.php b/apps/dav/tests/unit/DAV/LazyOpsPluginTest.php index 037360c6dc80..628a3a53df88 100644 --- a/apps/dav/tests/unit/DAV/LazyOpsPluginTest.php +++ b/apps/dav/tests/unit/DAV/LazyOpsPluginTest.php @@ -50,7 +50,7 @@ class LazyOpsPluginTest extends TestCase { /** @var IUserSession | \PHPUnit\Framework\MockObject\MockObject */ private $userSession; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->userSession = $this->createMock(IUserSession::class); diff --git a/apps/dav/tests/unit/DAV/LockPluginTest.php b/apps/dav/tests/unit/DAV/LockPluginTest.php index 68dfdb19b9f1..ea1dea9e2808 100644 --- a/apps/dav/tests/unit/DAV/LockPluginTest.php +++ b/apps/dav/tests/unit/DAV/LockPluginTest.php @@ -51,7 +51,7 @@ class LockPluginTest extends TestCase { /** @var IUserSession | \PHPUnit\Framework\MockObject\MockObject */ private $userSession; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->plugin = new LockPlugin(); @@ -67,16 +67,17 @@ public function setUp() { $this->overwriteService('UserSession', $this->userSession); } - protected function tearDown() { + protected function tearDown(): void { parent::tearDown(); $this->restoreService('UserSession'); $this->restoreService(LockMapper::class); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testBeforeUnlock() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $lock = new LockInfo(); $lock->token = '123-456-789'; diff --git a/apps/dav/tests/unit/DAV/MiscCustomPropertiesBackendTest.php b/apps/dav/tests/unit/DAV/MiscCustomPropertiesBackendTest.php index 250ef0e60236..4a3b8675438a 100644 --- a/apps/dav/tests/unit/DAV/MiscCustomPropertiesBackendTest.php +++ b/apps/dav/tests/unit/DAV/MiscCustomPropertiesBackendTest.php @@ -59,7 +59,7 @@ class MiscCustomPropertiesBackendTest extends \Test\TestCase { /** @var int */ private $maxId; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = new \Sabre\DAV\Server(); $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') @@ -90,7 +90,7 @@ public function setUp() { ->execute()->fetchColumn(); } - public function tearDown() { + public function tearDown(): void { $connection = \OC::$server->getDatabaseConnection(); $deleteStatement = $connection->prepare( 'DELETE FROM `*PREFIX*dav_properties`' . diff --git a/apps/dav/tests/unit/DAV/Sharing/PluginTest.php b/apps/dav/tests/unit/DAV/Sharing/PluginTest.php index f5d13888b03b..36630f874b48 100644 --- a/apps/dav/tests/unit/DAV/Sharing/PluginTest.php +++ b/apps/dav/tests/unit/DAV/Sharing/PluginTest.php @@ -41,7 +41,7 @@ class PluginTest extends TestCase { /** @var IShareable | \PHPUnit\Framework\MockObject\MockObject */ private $book; - public function setUp() { + public function setUp(): void { parent::setUp(); /** @var Auth | \PHPUnit\Framework\MockObject\MockObject $authBackend */ diff --git a/apps/dav/tests/unit/DAV/SystemPrincipalBackendTest.php b/apps/dav/tests/unit/DAV/SystemPrincipalBackendTest.php index d6960805ec56..c472df108598 100644 --- a/apps/dav/tests/unit/DAV/SystemPrincipalBackendTest.php +++ b/apps/dav/tests/unit/DAV/SystemPrincipalBackendTest.php @@ -79,13 +79,14 @@ public function providesPath() { /** * @dataProvider providesPrincipalForGetGroupMemberSet - * @expectedException \Sabre\DAV\Exception - * @expectedExceptionMessage Principal not found * * @param string $principal * @throws \Sabre\DAV\Exception */ public function testGetGroupMemberSetExceptional($principal) { + $this->expectException(\Sabre\DAV\Exception::class); + $this->expectExceptionMessage('Principal not found'); + $backend = new SystemPrincipalBackend(); $backend->getGroupMemberSet($principal); } @@ -108,13 +109,14 @@ public function testGetGroupMemberSet() { /** * @dataProvider providesPrincipalForGetGroupMembership - * @expectedException \Sabre\DAV\Exception - * @expectedExceptionMessage Principal not found * * @param string $principal * @throws \Sabre\DAV\Exception */ public function testGetGroupMembershipExceptional($principal) { + $this->expectException(\Sabre\DAV\Exception::class); + $this->expectExceptionMessage('Principal not found'); + $backend = new SystemPrincipalBackend(); $backend->getGroupMembership($principal); } diff --git a/apps/dav/tests/unit/DAV/ViewOnlyPluginTest.php b/apps/dav/tests/unit/DAV/ViewOnlyPluginTest.php index 577935be7b07..22ec2d64c208 100644 --- a/apps/dav/tests/unit/DAV/ViewOnlyPluginTest.php +++ b/apps/dav/tests/unit/DAV/ViewOnlyPluginTest.php @@ -43,7 +43,7 @@ class ViewOnlyPluginTest extends TestCase { /** @var RequestInterface | \PHPUnit\Framework\MockObject\MockObject */ private $request; - public function setUp() { + public function setUp(): void { $this->plugin = new ViewOnlyPlugin( $this->createMock(ILogger::class) ); diff --git a/apps/dav/tests/unit/Files/FileLocksBackendTest.php b/apps/dav/tests/unit/Files/FileLocksBackendTest.php index 7cecd6ada7f7..1f1e028e4cfa 100644 --- a/apps/dav/tests/unit/Files/FileLocksBackendTest.php +++ b/apps/dav/tests/unit/Files/FileLocksBackendTest.php @@ -49,7 +49,7 @@ class FileLocksBackendTest extends TestCase { /** @var IPersistentLockingStorage | IStorage | \PHPUnit\Framework\MockObject\MockObject */ private $storageOfFileToBeLocked; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->storageOfFileToBeLocked = $this->createMock([IPersistentLockingStorage::class, IStorage::class]); @@ -315,9 +315,10 @@ public function testLock() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\Forbidden */ public function testLockPublic() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + $lockInfo = new LockInfo(); $lockInfo->token = '123-456-7890'; $lockInfo->scope = LockInfo::SHARED; @@ -337,9 +338,10 @@ public function testLockPublic() { } /** - * @expectedException \OCA\DAV\Connector\Sabre\Exception\Forbidden */ public function testUnlockPublic() { + $this->expectException(\OCA\DAV\Connector\Sabre\Exception\Forbidden::class); + $lockInfo = new LockInfo(); $lockInfo->token = '123-456-7890'; $lockInfo->scope = LockInfo::SHARED; diff --git a/apps/dav/tests/unit/Files/FilesHomeTest.php b/apps/dav/tests/unit/Files/FilesHomeTest.php index ec984fc23927..90d970f75466 100644 --- a/apps/dav/tests/unit/Files/FilesHomeTest.php +++ b/apps/dav/tests/unit/Files/FilesHomeTest.php @@ -37,7 +37,7 @@ class FilesHomeTest extends TestCase { /** @var View | \PHPUnit\Framework\MockObject\MockObject */ private $view; - protected function setUp() { + protected function setUp(): void { $this->view = $this->createMock(View::class); $this->filesHome = new FilesHome([ 'uri' => 'principals/users/user01' @@ -55,20 +55,22 @@ public function testGetName() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to rename this folder * @throws \Sabre\DAV\Exception\Forbidden */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to rename this folder'); + $this->filesHome->setName('alice'); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to delete home folder * @throws \Sabre\DAV\Exception\Forbidden */ public function testDelete() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to delete home folder'); + $this->filesHome->delete(); } diff --git a/apps/dav/tests/unit/Files/PreviewPluginTest.php b/apps/dav/tests/unit/Files/PreviewPluginTest.php index 01b08a7e0050..759c917f07e7 100644 --- a/apps/dav/tests/unit/Files/PreviewPluginTest.php +++ b/apps/dav/tests/unit/Files/PreviewPluginTest.php @@ -53,7 +53,7 @@ class PreviewPluginTest extends TestCase { /** @var ResponseInterface| \PHPUnit\Framework\MockObject\MockObject */ private $response; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->previewManager = $this->createMock(IPreview::class); diff --git a/apps/dav/tests/unit/Files/PublicFiles/PublicSharedRootNodeTest.php b/apps/dav/tests/unit/Files/PublicFiles/PublicSharedRootNodeTest.php index 27fe74fe82ed..ea40e0427edd 100644 --- a/apps/dav/tests/unit/Files/PublicFiles/PublicSharedRootNodeTest.php +++ b/apps/dav/tests/unit/Files/PublicFiles/PublicSharedRootNodeTest.php @@ -30,9 +30,10 @@ class PublicSharedRootNodeTest extends TestCase { /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testNoLongerExistingResource() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $share = $this->createMock(IShare::class); $request = $this->createMock(IRequest::class); $share->method('getNode')->willThrowException(new NotFoundException()); diff --git a/apps/dav/tests/unit/Files/Sharing/PublicLinkEventsPluginTest.php b/apps/dav/tests/unit/Files/Sharing/PublicLinkEventsPluginTest.php index 492f1edd9abe..6007f36297f0 100644 --- a/apps/dav/tests/unit/Files/Sharing/PublicLinkEventsPluginTest.php +++ b/apps/dav/tests/unit/Files/Sharing/PublicLinkEventsPluginTest.php @@ -37,7 +37,7 @@ class PublicLinkEventsPluginTest extends TestCase { /** @var PublicLinkEventsPlugin */ private $publicLinkEventsPlugin; - protected function setUp() { + protected function setUp(): void { $this->dispatcher = $this->createMock(EventDispatcherInterface::class); $this->server = $this->createMock(Server::class); diff --git a/apps/dav/tests/unit/JobStatus/Entity/JobStatusMapperTest.php b/apps/dav/tests/unit/JobStatus/Entity/JobStatusMapperTest.php index 649e99ffdc5c..35a8f22fd4ba 100644 --- a/apps/dav/tests/unit/JobStatus/Entity/JobStatusMapperTest.php +++ b/apps/dav/tests/unit/JobStatus/Entity/JobStatusMapperTest.php @@ -42,7 +42,7 @@ class JobStatusMapperTest extends TestCase { /** @var JobStatus */ private $testJobStatus; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->database = \OC::$server->getDatabaseConnection(); $this->mapper = new JobStatusMapper($this->database); @@ -54,7 +54,7 @@ public function setUp() { $this->testJobStatus->setStatusInfo(\json_encode([])); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); if ($this->mapper !== null && $this->testJobStatus !== null) { $this->mapper->delete($this->testJobStatus); @@ -62,9 +62,10 @@ public function tearDown() { } /** - * @expectedException \Doctrine\DBAL\Exception\UniqueConstraintViolationException */ public function testInsert() { + $this->expectException(\Doctrine\DBAL\Exception\UniqueConstraintViolationException::class); + $this->mapper->insert($this->testJobStatus); $this->assertNotNull($this->testJobStatus->getId()); // below throws exception due to unique constraint violation diff --git a/apps/dav/tests/unit/JobStatus/HomeTest.php b/apps/dav/tests/unit/JobStatus/HomeTest.php index 4e098b11c3ac..c0fe1f51cc40 100644 --- a/apps/dav/tests/unit/JobStatus/HomeTest.php +++ b/apps/dav/tests/unit/JobStatus/HomeTest.php @@ -42,9 +42,10 @@ public function testGetName() { } /** - * @expectedException \Sabre\DAV\Exception\MethodNotAllowed */ public function testGetChildren() { + $this->expectException(\Sabre\DAV\Exception\MethodNotAllowed::class); + /** @var JobStatusMapper | \PHPUnit\Framework\MockObject\MockObject $mapper */ $mapper = $this->createMock(JobStatusMapper::class); $home = new Home(['uri' => 'principals/users/user1'], $mapper); @@ -64,9 +65,10 @@ public function testGetChild() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetChildNotFound() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + /** @var JobStatusMapper | \PHPUnit\Framework\MockObject\MockObject $mapper */ $mapper = $this->createMock(JobStatusMapper::class); diff --git a/apps/dav/tests/unit/JobStatus/JobStatusTest.php b/apps/dav/tests/unit/JobStatus/JobStatusTest.php index 124c8f7e9822..e0ab645fdc8d 100644 --- a/apps/dav/tests/unit/JobStatus/JobStatusTest.php +++ b/apps/dav/tests/unit/JobStatus/JobStatusTest.php @@ -40,7 +40,7 @@ class JobStatusTest extends TestCase { /** @var JobStatusMapper | \PHPUnit\Framework\MockObject\MockObject */ private $mapper; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->mapper = $this->createMock(JobStatusMapper::class); diff --git a/apps/dav/tests/unit/Meta/MetaPluginTest.php b/apps/dav/tests/unit/Meta/MetaPluginTest.php index cdf502d53e86..8c033567738a 100644 --- a/apps/dav/tests/unit/Meta/MetaPluginTest.php +++ b/apps/dav/tests/unit/Meta/MetaPluginTest.php @@ -48,7 +48,7 @@ class MetaPluginTest extends TestCase { */ private $server; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->userSession = $this->createMock(IUserSession::class); diff --git a/apps/dav/tests/unit/Repair/RemoveInvalidSharesTest.php b/apps/dav/tests/unit/Repair/RemoveInvalidSharesTest.php index 361905b7f95b..55f3ce2ab5a2 100644 --- a/apps/dav/tests/unit/Repair/RemoveInvalidSharesTest.php +++ b/apps/dav/tests/unit/Repair/RemoveInvalidSharesTest.php @@ -34,7 +34,7 @@ * @group DB */ class RemoveInvalidSharesTest extends TestCase { - public function setUp() { + public function setUp(): void { parent::setUp(); $db = \OC::$server->getDatabaseConnection(); diff --git a/apps/dav/tests/unit/SystemTag/SystemTagMappingNodeTest.php b/apps/dav/tests/unit/SystemTag/SystemTagMappingNodeTest.php index 33762e330139..9bdc5c6bd35c 100644 --- a/apps/dav/tests/unit/SystemTag/SystemTagMappingNodeTest.php +++ b/apps/dav/tests/unit/SystemTag/SystemTagMappingNodeTest.php @@ -44,7 +44,7 @@ class SystemTagMappingNodeTest extends \Test\TestCase { */ private $user; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->tagManager = $this->createMock('\OCP\SystemTag\ISystemTagManager'); @@ -139,9 +139,10 @@ public function testDeleteTagExpectedException(ISystemTag $tag, $expectedExcepti } /** - * @expectedException Sabre\DAV\Exception\NotFound */ public function testDeleteTagNotFound() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + // assuming the tag existed at the time the node was created, // but got deleted concurrently in the database $tag = new SystemTag(1, 'Test', true, true); @@ -164,9 +165,10 @@ public function testDeleteTagNotFound() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testeDeteteTagNotAllowedStaticTag() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $tag = new SystemTag(1, 'Test', true, true, false); $this->tagManager->method('canUserSeeTag') ->willReturn(true); diff --git a/apps/dav/tests/unit/SystemTag/SystemTagNodeTest.php b/apps/dav/tests/unit/SystemTag/SystemTagNodeTest.php index 9c9861d6cf02..c410ee4c3d2c 100644 --- a/apps/dav/tests/unit/SystemTag/SystemTagNodeTest.php +++ b/apps/dav/tests/unit/SystemTag/SystemTagNodeTest.php @@ -40,7 +40,7 @@ class SystemTagNodeTest extends \Test\TestCase { */ private $user; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->tagManager = $this->createMock('\OCP\SystemTag\ISystemTagManager'); @@ -74,9 +74,10 @@ public function testGetters($isAdmin) { } /** - * @expectedException Sabre\DAV\Exception\MethodNotAllowed */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\MethodNotAllowed::class); + $this->getTagNode()->setName('2'); } @@ -193,9 +194,10 @@ public function testUpdateTagPermissionException($originalTag, $changedArgs, $ex } /** - * @expectedException Sabre\DAV\Exception\Conflict */ public function testUpdateTagAlreadyExists() { + $this->expectException(\Sabre\DAV\Exception\Conflict::class); + $tag = new SystemTag(1, 'tag1', true, true); $this->tagManager->expects($this->any()) ->method('canUserSeeTag') @@ -215,9 +217,10 @@ public function testUpdateTagAlreadyExists() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testStaticTagUpdateFail() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $tag = new SystemTag(1, 'tag1', true, true, false); $this->tagManager->expects($this->any()) ->method('canUserSeeTag') @@ -231,9 +234,10 @@ public function testStaticTagUpdateFail() { } /** - * @expectedException Sabre\DAV\Exception\NotFound */ public function testUpdateTagNotFound() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $tag = new SystemTag(1, 'tag1', true, true); $this->tagManager->expects($this->any()) ->method('canUserSeeTag') @@ -313,9 +317,10 @@ public function testDeleteTagPermissionException(ISystemTag $tag, $expectedExcep } /** - * @expectedException Sabre\DAV\Exception\NotFound */ public function testDeleteTagNotFound() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $tag = new SystemTag(1, 'tag1', true, true); $this->tagManager->expects($this->any()) ->method('canUserSeeTag') @@ -335,9 +340,10 @@ public function testDeleteTagNotFound() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testStaticTagExceptionForDelete() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $tag = new SystemTag(1, 'tag1', true, true, false); $this->tagManager->expects($this->any()) ->method('canUserSeeTag') diff --git a/apps/dav/tests/unit/SystemTag/SystemTagPluginTest.php b/apps/dav/tests/unit/SystemTag/SystemTagPluginTest.php index 7274468dea82..dc122766857a 100644 --- a/apps/dav/tests/unit/SystemTag/SystemTagPluginTest.php +++ b/apps/dav/tests/unit/SystemTag/SystemTagPluginTest.php @@ -77,7 +77,7 @@ class SystemTagPluginTest extends \Test\TestCase { */ private $plugin; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') ->disableOriginalConstructor() @@ -227,9 +227,10 @@ public function testGetProperties(ISystemTag $systemTag, $groups, $requestedProp } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testGetPropertiesForbidden() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $systemTag = new SystemTag(1, 'Test', true, false); $requestedProperties = [ self::ID_PROPERTYNAME, @@ -326,9 +327,10 @@ public function testUpdatePropertiesAdmin() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden */ public function testUpdatePropertiesForbidden() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $systemTag = new SystemTag(1, 'Test', true, false); $this->user->expects($this->any()) ->method('getUID') @@ -379,10 +381,11 @@ public function createTagInsufficientPermissionsProvider() { } /** * @dataProvider createTagInsufficientPermissionsProvider - * @expectedException \Sabre\DAV\Exception\BadRequest - * @expectedExceptionMessage Not sufficient permissions */ public function testCreateNotAssignableTagAsRegularUser($userVisible, $userAssignable, $userEditable, $groups) { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $this->expectExceptionMessage('Not sufficient permissions'); + $this->user->expects($this->once()) ->method('getUID') ->willReturn('admin'); @@ -655,9 +658,10 @@ public function testCreateTagInMappingCollection() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testCreateTagToUnknownNode() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $node = $this->getMockBuilder('\OCA\DAV\SystemTag\SystemTagsObjectMappingCollection') ->disableOriginalConstructor() ->getMock(); @@ -688,9 +692,10 @@ public function testCreateTagToUnknownNode() { /** * @dataProvider nodeClassProvider - * @expectedException \Sabre\DAV\Exception\Conflict */ public function testCreateTagConflict($nodeClass) { + $this->expectException(\Sabre\DAV\Exception\Conflict::class); + $this->user->expects($this->once()) ->method('getUID') ->willReturn('admin'); diff --git a/apps/dav/tests/unit/SystemTag/SystemTagsByIdCollectionTest.php b/apps/dav/tests/unit/SystemTag/SystemTagsByIdCollectionTest.php index a7dc867f3e70..aa0384d3a8f0 100644 --- a/apps/dav/tests/unit/SystemTag/SystemTagsByIdCollectionTest.php +++ b/apps/dav/tests/unit/SystemTag/SystemTagsByIdCollectionTest.php @@ -39,7 +39,7 @@ class SystemTagsByIdCollectionTest extends \Test\TestCase { */ private $user; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->tagManager = $this->createMock('\OCP\SystemTag\ISystemTagManager'); @@ -71,16 +71,18 @@ public function adminFlagProvider() { } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testForbiddenCreateFile() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->getNode()->createFile('555'); } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testForbiddenCreateDirectory() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->getNode()->createDirectory('789'); } @@ -104,9 +106,10 @@ public function testGetChild() { } /** - * @expectedException Sabre\DAV\Exception\BadRequest */ public function testGetChildInvalidName() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $this->tagManager->expects($this->once()) ->method('getTagsByIds') ->with(['invalid']) @@ -116,9 +119,10 @@ public function testGetChildInvalidName() { } /** - * @expectedException Sabre\DAV\Exception\NotFound */ public function testGetChildNotFound() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $this->tagManager->expects($this->once()) ->method('getTagsByIds') ->with(['444']) @@ -128,9 +132,10 @@ public function testGetChildNotFound() { } /** - * @expectedException Sabre\DAV\Exception\NotFound */ public function testGetChildUserNotVisible() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $tag = new SystemTag(123, 'Test', false, false); $this->tagManager->expects($this->once()) @@ -281,9 +286,10 @@ public function testChildExistsNotFound() { } /** - * @expectedException Sabre\DAV\Exception\BadRequest */ public function testChildExistsBadRequest() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $this->tagManager->expects($this->once()) ->method('getTagsByIds') ->with(['invalid']) diff --git a/apps/dav/tests/unit/SystemTag/SystemTagsObjectMappingCollectionTest.php b/apps/dav/tests/unit/SystemTag/SystemTagsObjectMappingCollectionTest.php index f00d95c3171b..9dbb94c58d7e 100644 --- a/apps/dav/tests/unit/SystemTag/SystemTagsObjectMappingCollectionTest.php +++ b/apps/dav/tests/unit/SystemTag/SystemTagsObjectMappingCollectionTest.php @@ -43,7 +43,7 @@ class SystemTagsObjectMappingCollectionTest extends \Test\TestCase { */ private $user; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->tagManager = $this->createMock('\OCP\SystemTag\ISystemTagManager'); @@ -127,10 +127,11 @@ public function testAssignTagNoPermission($userVisible, $userAssignable, $expect } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage No permission to assign tag 555 */ public function testStaticTagAssignNoPermission() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('No permission to assign tag 555'); + $tag = new SystemTag('1', 'Test', true, true, false); $this->tagManager->expects($this->once()) ->method('getTagsByIds') @@ -147,9 +148,10 @@ public function testStaticTagAssignNoPermission() { } /** - * @expectedException Sabre\DAV\Exception\PreconditionFailed */ public function testAssignTagNotFound() { + $this->expectException(\Sabre\DAV\Exception\PreconditionFailed::class); + $this->tagManager->expects($this->once()) ->method('getTagsByIds') ->with(['555']) @@ -159,9 +161,10 @@ public function testAssignTagNotFound() { } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testForbiddenCreateDirectory() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->getNode()->createDirectory('789'); } @@ -189,9 +192,10 @@ public function testGetChild() { } /** - * @expectedException \Sabre\DAV\Exception\NotFound */ public function testGetChildNonVisible() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $tag = new SystemTag(555, 'TheTag', false, false); $this->tagManager->expects($this->once()) ->method('canUserSeeTag') @@ -212,9 +216,10 @@ public function testGetChildNonVisible() { } /** - * @expectedException Sabre\DAV\Exception\NotFound */ public function testGetChildRelationNotFound() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $this->tagMapper->expects($this->once()) ->method('haveTag') ->with([111], 'files', '777') @@ -224,9 +229,10 @@ public function testGetChildRelationNotFound() { } /** - * @expectedException Sabre\DAV\Exception\BadRequest */ public function testGetChildInvalidId() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $this->tagMapper->expects($this->once()) ->method('haveTag') ->with([111], 'files', 'badid') @@ -236,9 +242,10 @@ public function testGetChildInvalidId() { } /** - * @expectedException Sabre\DAV\Exception\NotFound */ public function testGetChildTagDoesNotExist() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $this->tagMapper->expects($this->once()) ->method('haveTag') ->with([111], 'files', '777') @@ -340,9 +347,10 @@ public function testChildExistsTagNotFound() { } /** - * @expectedException Sabre\DAV\Exception\BadRequest */ public function testChildExistsInvalidId() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $this->tagMapper->expects($this->once()) ->method('haveTag') ->with([111], 'files', '555') @@ -352,16 +360,18 @@ public function testChildExistsInvalidId() { } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testDelete() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->getNode()->delete(); } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->getNode()->setName('somethingelse'); } diff --git a/apps/dav/tests/unit/SystemTag/SystemTagsObjectTypeCollectionTest.php b/apps/dav/tests/unit/SystemTag/SystemTagsObjectTypeCollectionTest.php index 5aa5bb64cfe9..cb5eed9b2256 100644 --- a/apps/dav/tests/unit/SystemTag/SystemTagsObjectTypeCollectionTest.php +++ b/apps/dav/tests/unit/SystemTag/SystemTagsObjectTypeCollectionTest.php @@ -45,7 +45,7 @@ class SystemTagsObjectTypeCollectionTest extends \Test\TestCase { */ private $userFolder; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->tagManager = $this->createMock('\OCP\SystemTag\ISystemTagManager'); @@ -84,16 +84,18 @@ protected function setUp() { } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testForbiddenCreateFile() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->node->createFile('555'); } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testForbiddenCreateDirectory() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->node->createDirectory('789'); } @@ -109,9 +111,10 @@ public function testGetChild() { } /** - * @expectedException Sabre\DAV\Exception\NotFound */ public function testGetChildWithoutAccess() { + $this->expectException(\Sabre\DAV\Exception\NotFound::class); + $this->userFolder->expects($this->once()) ->method('getById') ->with('555') @@ -120,9 +123,10 @@ public function testGetChildWithoutAccess() { } /** - * @expectedException Sabre\DAV\Exception\MethodNotAllowed */ public function testGetChildren() { + $this->expectException(\Sabre\DAV\Exception\MethodNotAllowed::class); + $this->node->getChildren(); } @@ -143,16 +147,18 @@ public function testChildExistsWithoutAccess() { } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testDelete() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->node->delete(); } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->node->setName('somethingelse'); } diff --git a/apps/dav/tests/unit/TrashBin/TrashBinFileTest.php b/apps/dav/tests/unit/TrashBin/TrashBinFileTest.php index f9567519c27c..05bd7bd63856 100644 --- a/apps/dav/tests/unit/TrashBin/TrashBinFileTest.php +++ b/apps/dav/tests/unit/TrashBin/TrashBinFileTest.php @@ -51,7 +51,7 @@ public function providesExceptions() : array { ]; } - protected function setUp() { + protected function setUp(): void { parent::setUp(); $fileInfo = $this->createMock(FileInfo::class); $this->trashBinManager = $this->createMock(TrashBinManager::class); @@ -59,26 +59,29 @@ protected function setUp() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to write this file */ public function testPut() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to write this file'); + $this->trashBinFile->put(''); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to read this file */ public function testGet() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to read this file'); + $this->trashBinFile->get(); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to rename this resource */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to rename this resource'); + $this->trashBinFile->setName(''); } diff --git a/apps/dav/tests/unit/TrashBin/TrashBinFolderTest.php b/apps/dav/tests/unit/TrashBin/TrashBinFolderTest.php index 917ea875fe8d..b8cb50d74ceb 100644 --- a/apps/dav/tests/unit/TrashBin/TrashBinFolderTest.php +++ b/apps/dav/tests/unit/TrashBin/TrashBinFolderTest.php @@ -42,7 +42,7 @@ class TrashBinFolderTest extends TestCase { */ private $fileInfo; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->fileInfo = $this->createMock(FileInfo::class); $this->trashBinManager = $this->createMock(TrashBinManager::class); @@ -59,26 +59,29 @@ protected function setUp() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to create a file */ public function testCreateFile() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to create a file'); + $this->trashBinFolder->createFile(''); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to create a folder */ public function testCreateFolder() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to create a folder'); + $this->trashBinFolder->createDirectory(''); } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to rename this resource */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to rename this resource'); + $this->trashBinFolder->setName(''); } diff --git a/apps/dav/tests/unit/TrashBin/TrashBinHomeTest.php b/apps/dav/tests/unit/TrashBin/TrashBinHomeTest.php index adf90bdc3eda..212fff7a7f49 100644 --- a/apps/dav/tests/unit/TrashBin/TrashBinHomeTest.php +++ b/apps/dav/tests/unit/TrashBin/TrashBinHomeTest.php @@ -36,7 +36,7 @@ class TrashBinHomeTest extends TestCase { */ private $trashBinManager; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->trashBinManager = $this->createMock(TrashBinManager::class); $this->trashBinHome = new TrashBinHome([ @@ -45,10 +45,11 @@ protected function setUp() { } /** - * @expectedException \Sabre\DAV\Exception\Forbidden - * @expectedExceptionMessage Permission denied to rename this folder */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $this->expectExceptionMessage('Permission denied to rename this folder'); + $this->trashBinHome->setName(''); } diff --git a/apps/dav/tests/unit/TreeTest.php b/apps/dav/tests/unit/TreeTest.php index c4b4027031a0..0a6d716fb05b 100644 --- a/apps/dav/tests/unit/TreeTest.php +++ b/apps/dav/tests/unit/TreeTest.php @@ -45,7 +45,7 @@ public function providesPaths() { ]; } - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->rootNode = $this->createMock(ICollection::class); diff --git a/apps/dav/tests/unit/Upload/ChunkLocationProviderTest.php b/apps/dav/tests/unit/Upload/ChunkLocationProviderTest.php index 38401e545c16..7eb6ff747173 100644 --- a/apps/dav/tests/unit/Upload/ChunkLocationProviderTest.php +++ b/apps/dav/tests/unit/Upload/ChunkLocationProviderTest.php @@ -39,7 +39,7 @@ class ChunkLocationProviderTest extends TestCase { /** @var IStorageFactory | \PHPUnit\Framework\MockObject\MockObject */ private $factory; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->config = $this->createMock(IConfig::class); $this->provider = new ChunkLocationProvider($this->config); diff --git a/apps/dav/tests/unit/Upload/ChunkingPluginTest.php b/apps/dav/tests/unit/Upload/ChunkingPluginTest.php index fee71266cc53..3ca256931b77 100644 --- a/apps/dav/tests/unit/Upload/ChunkingPluginTest.php +++ b/apps/dav/tests/unit/Upload/ChunkingPluginTest.php @@ -49,7 +49,7 @@ class ChunkingPluginTest extends TestCase { /** @var ResponseInterface | \PHPUnit\Framework\MockObject\MockObject */ private $response; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->server = $this->getMockBuilder('\Sabre\DAV\Server') @@ -140,10 +140,11 @@ public function testBeforeMoveFutureFileMoveIt() { } /** - * @expectedException \Sabre\DAV\Exception\BadRequest - * @expectedExceptionMessage Chunks on server do not sum up to 4 but to 3 */ public function testBeforeMoveSizeIsWrong() { + $this->expectException(\Sabre\DAV\Exception\BadRequest::class); + $this->expectExceptionMessage('Chunks on server do not sum up to 4 but to 3'); + $sourceNode = $this->createMock(FutureFile::class); $sourceNode->expects($this->once()) ->method('getSize') diff --git a/apps/dav/tests/unit/Upload/FutureFileTest.php b/apps/dav/tests/unit/Upload/FutureFileTest.php index ca7814411d76..0a4afbe0d922 100644 --- a/apps/dav/tests/unit/Upload/FutureFileTest.php +++ b/apps/dav/tests/unit/Upload/FutureFileTest.php @@ -51,7 +51,7 @@ public function testGetSize() { public function testGet() { $f = $this->mockFutureFile(); $stream = $f->get(); - $this->assertInternalType('resource', $stream); + $this->assertIsResource($stream); } public function testDelete() { @@ -68,17 +68,19 @@ public function testDelete() { } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testPut() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $f = $this->mockFutureFile(); $f->put(''); } /** - * @expectedException Sabre\DAV\Exception\Forbidden */ public function testSetName() { + $this->expectException(\Sabre\DAV\Exception\Forbidden::class); + $f = $this->mockFutureFile(); $f->setName(''); } diff --git a/apps/federatedfilesharing/tests/AddressHandlerTest.php b/apps/federatedfilesharing/tests/AddressHandlerTest.php index 415e033e27e2..18c0114e64aa 100644 --- a/apps/federatedfilesharing/tests/AddressHandlerTest.php +++ b/apps/federatedfilesharing/tests/AddressHandlerTest.php @@ -38,7 +38,7 @@ class AddressHandlerTest extends \Test\TestCase { /** @var IL10N | \PHPUnit\Framework\MockObject\MockObject */ private $il10n; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->urlGenerator = $this->createMock('OCP\IURLGenerator'); @@ -113,9 +113,10 @@ public function dataTestSplitUserRemoteError() { * @dataProvider dataTestSplitUserRemoteError * * @param string $id - * @expectedException \OC\HintException */ public function testSplitUserRemoteError($id) { + $this->expectException(\OC\HintException::class); + $this->addressHandler->splitUserRemote($id); } diff --git a/apps/federatedfilesharing/tests/Command/PollIncomingSharesTest.php b/apps/federatedfilesharing/tests/Command/PollIncomingSharesTest.php index 2c146df53b9a..d956580c95c7 100644 --- a/apps/federatedfilesharing/tests/Command/PollIncomingSharesTest.php +++ b/apps/federatedfilesharing/tests/Command/PollIncomingSharesTest.php @@ -65,7 +65,7 @@ class PollIncomingSharesTest extends TestCase { */ private $externalManager; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->dbConnection = $this->createMock(IDBConnection::class); $this->userManager = $this->createMock(IUserManager::class); @@ -106,7 +106,10 @@ public function testWithFilesSharingDisabled() { $this->commandTester = new CommandTester($command); $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains("Polling is not possible when files_sharing app is disabled. Please enable it with 'occ app:enable files_sharing'", $output); + $this->assertStringContainsString( + "Polling is not possible when files_sharing app is disabled. Please enable it with 'occ app:enable files_sharing'", + $output + ); } public function testUnavailableStorage() { @@ -143,7 +146,7 @@ public function testUnavailableStorage() { $this->dbConnection->method('getQueryBuilder')->willReturn($qbMock); $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains( + $this->assertStringContainsString( 'Skipping external share with id "50" from remote "example.org". Reason: "Ooops"', $output ); @@ -166,7 +169,7 @@ public function testNotExistingUser() { $this->dbConnection->method('getQueryBuilder')->willReturn($qbMock); $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains( + $this->assertStringContainsString( 'Skipping user "foo". Reason: user manager was unable to resolve the uid into the user object', $output ); @@ -207,7 +210,7 @@ public function testPollingUnsharedMount() { $this->dbConnection->method('getQueryBuilder')->willReturn($qbMock); $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains( + $this->assertStringContainsString( 'Remote "example.org" reports that external share with id "50" no longer exists. Removing it..', $output ); diff --git a/apps/federatedfilesharing/tests/Controller/OcmControllerTest.php b/apps/federatedfilesharing/tests/Controller/OcmControllerTest.php index 1243da907009..2a953a2ddf1b 100644 --- a/apps/federatedfilesharing/tests/Controller/OcmControllerTest.php +++ b/apps/federatedfilesharing/tests/Controller/OcmControllerTest.php @@ -96,7 +96,7 @@ class OcmControllerTest extends TestCase { */ private $shareToken = 'abc'; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->request = $this->createMock(IRequest::class); diff --git a/apps/federatedfilesharing/tests/Controller/RequestHandlerTest.php b/apps/federatedfilesharing/tests/Controller/RequestHandlerTest.php index 4e8f4e4fbb0a..6da812747fe7 100644 --- a/apps/federatedfilesharing/tests/Controller/RequestHandlerTest.php +++ b/apps/federatedfilesharing/tests/Controller/RequestHandlerTest.php @@ -82,7 +82,7 @@ class RequestHandlerTest extends TestCase { */ private $requestHandlerController; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->request = $this->createMock(IRequest::class); diff --git a/apps/federatedfilesharing/tests/Controller/SharingPersonalSettingsControllerTest.php b/apps/federatedfilesharing/tests/Controller/SharingPersonalSettingsControllerTest.php index a5037c447c61..765c98b4739a 100644 --- a/apps/federatedfilesharing/tests/Controller/SharingPersonalSettingsControllerTest.php +++ b/apps/federatedfilesharing/tests/Controller/SharingPersonalSettingsControllerTest.php @@ -44,7 +44,7 @@ class SharingPersonalSettingsControllerTest extends TestCase { /** @var SharingPersonalSettingsController $personalSettingsController */ private $sharingPersonalSettingsController; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->config = $this->getMockBuilder(IConfig::class) ->disableOriginalConstructor() diff --git a/apps/federatedfilesharing/tests/DiscoveryManagerTest.php b/apps/federatedfilesharing/tests/DiscoveryManagerTest.php index e9edc6bbc437..7ca1a36c709e 100644 --- a/apps/federatedfilesharing/tests/DiscoveryManagerTest.php +++ b/apps/federatedfilesharing/tests/DiscoveryManagerTest.php @@ -38,7 +38,7 @@ class DiscoveryManagerTest extends \Test\TestCase { /** @var DiscoveryManager */ private $discoveryManager; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->cache = $this->createMock('\OCP\ICache'); /** @var ICacheFactory $cacheFactory */ diff --git a/apps/federatedfilesharing/tests/FedShareManagerTest.php b/apps/federatedfilesharing/tests/FedShareManagerTest.php index 226f9e6cdf60..b089e87f4a41 100644 --- a/apps/federatedfilesharing/tests/FedShareManagerTest.php +++ b/apps/federatedfilesharing/tests/FedShareManagerTest.php @@ -71,7 +71,7 @@ class FedShareManagerTest extends TestCase { /** @var EventDispatcherInterface | \PHPUnit\Framework\MockObject\MockObject */ private $eventDispatcher; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->federatedShareProvider = $this->getMockBuilder( diff --git a/apps/federatedfilesharing/tests/FederatedShareProviderTest.php b/apps/federatedfilesharing/tests/FederatedShareProviderTest.php index f5a7ddea4483..e5d7f4996164 100644 --- a/apps/federatedfilesharing/tests/FederatedShareProviderTest.php +++ b/apps/federatedfilesharing/tests/FederatedShareProviderTest.php @@ -79,7 +79,7 @@ class FederatedShareProviderTest extends \Test\TestCase { /** @var FederatedShareProvider */ protected $provider; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); @@ -121,10 +121,10 @@ public function setUp() { $this->shareManager = \OC::$server->getShareManager(); } - public function tearDown() { + public function tearDown(): void { $this->connection->getQueryBuilder()->delete('share')->execute(); - return parent::tearDown(); + parent::tearDown(); } public function testCreate() { @@ -172,10 +172,10 @@ public function testCreate() { ->where($qb->expr()->eq('id', $qb->createNamedParameter($share->getId()))) ->execute(); - $data = $stmt->fetch(); + $fetchedData = $stmt->fetch(); $stmt->closeCursor(); - $expected = [ + $expectedSubset = [ 'share_type' => \OCP\Share::SHARE_TYPE_REMOTE, 'share_with' => 'user@server.com', 'uid_owner' => 'shareOwner', @@ -187,9 +187,12 @@ public function testCreate() { 'accepted' => 0, 'token' => 'token', ]; - $this->assertArraySubset($expected, $data); + foreach ($expectedSubset as $key => $value) { + $this->assertArrayHasKey($key, $fetchedData); + $this->assertEquals($value, $fetchedData[$key]); + } - $this->assertEquals($data['id'], $share->getId()); + $this->assertEquals($fetchedData['id'], $share->getId()); $this->assertEquals(\OCP\Share::SHARE_TYPE_REMOTE, $share->getShareType()); $this->assertEquals('user@server.com', $share->getSharedWith()); $this->assertEquals('sharedBy', $share->getSharedBy()); @@ -256,10 +259,10 @@ public function testCreateLegacy() { ->where($qb->expr()->eq('id', $qb->createNamedParameter($share->getId()))) ->execute(); - $data = $stmt->fetch(); + $fetchedData = $stmt->fetch(); $stmt->closeCursor(); - $expected = [ + $expectedSubset = [ 'share_type' => \OCP\Share::SHARE_TYPE_REMOTE, 'share_with' => 'user@server.com', 'uid_owner' => 'shareOwner', @@ -271,9 +274,12 @@ public function testCreateLegacy() { 'accepted' => 0, 'token' => 'token', ]; - $this->assertArraySubset($expected, $data); + foreach ($expectedSubset as $key => $value) { + $this->assertArrayHasKey($key, $fetchedData); + $this->assertEquals($value, $fetchedData[$key]); + } - $this->assertEquals($data['id'], $share->getId()); + $this->assertEquals($fetchedData['id'], $share->getId()); $this->assertEquals(\OCP\Share::SHARE_TYPE_REMOTE, $share->getShareType()); $this->assertEquals('user@server.com', $share->getSharedWith()); $this->assertEquals('shareOwner', $share->getSharedBy()); diff --git a/apps/federatedfilesharing/tests/Middleware/OcmMiddlewareTest.php b/apps/federatedfilesharing/tests/Middleware/OcmMiddlewareTest.php index 8c3151f8ddcc..087e29d479cc 100644 --- a/apps/federatedfilesharing/tests/Middleware/OcmMiddlewareTest.php +++ b/apps/federatedfilesharing/tests/Middleware/OcmMiddlewareTest.php @@ -71,7 +71,7 @@ class OcmMiddlewareTest extends TestCase { */ private $logger; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->federatedShareProvider = $this->createMock( diff --git a/apps/federatedfilesharing/tests/NotificationsTest.php b/apps/federatedfilesharing/tests/NotificationsTest.php index 8d807ddd1858..222dc35fbb48 100644 --- a/apps/federatedfilesharing/tests/NotificationsTest.php +++ b/apps/federatedfilesharing/tests/NotificationsTest.php @@ -57,7 +57,7 @@ class NotificationsTest extends \Test\TestCase { /** @var IConfig | \PHPUnit\Framework\MockObject\MockObject */ private $config; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->jobList = $this->createMock(IJobList::class); diff --git a/apps/federatedfilesharing/tests/Ocm/PermissionsTest.php b/apps/federatedfilesharing/tests/Ocm/PermissionsTest.php index f2734c597d20..107b2500c529 100644 --- a/apps/federatedfilesharing/tests/Ocm/PermissionsTest.php +++ b/apps/federatedfilesharing/tests/Ocm/PermissionsTest.php @@ -37,7 +37,7 @@ class PermissionsTest extends TestCase { */ private $permissions; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->permissions = new Permissions(); } diff --git a/apps/federatedfilesharing/tests/Panels/AdminPanelTest.php b/apps/federatedfilesharing/tests/Panels/AdminPanelTest.php index da0da9c64a7f..b073181cbc04 100644 --- a/apps/federatedfilesharing/tests/Panels/AdminPanelTest.php +++ b/apps/federatedfilesharing/tests/Panels/AdminPanelTest.php @@ -37,7 +37,7 @@ class AdminPanelTest extends \Test\TestCase { /** @var IConfig */ private $config; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->shareProvider = $this->getMockBuilder(FederatedShareProvider::class) ->disableOriginalConstructor() @@ -51,7 +51,7 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); } public function testGetPanel() { diff --git a/apps/federatedfilesharing/tests/Panels/GeneralPersonalPanelTest.php b/apps/federatedfilesharing/tests/Panels/GeneralPersonalPanelTest.php index 209abea65e6b..c8aabce2d201 100644 --- a/apps/federatedfilesharing/tests/Panels/GeneralPersonalPanelTest.php +++ b/apps/federatedfilesharing/tests/Panels/GeneralPersonalPanelTest.php @@ -47,7 +47,7 @@ class GeneralPersonalPanelTest extends \Test\TestCase { /** @var IRequest */ private $request; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->l = $this->getMockBuilder(IL10N::class)->getMock(); $this->urlGenerator = $this->getMockBuilder(IURLGenerator::class)->getMock(); @@ -68,7 +68,7 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); $this->assertTrue($this->panel->getPriority() < 50); } @@ -79,6 +79,6 @@ public function testGetPanel() { $this->userSession->expects($this->once())->method('getUser')->willReturn($mockUser); $this->shareProvider->expects($this->once())->method('isOutgoingServer2serverShareEnabled')->willReturn(true); $templateHtml = $this->panel->getPanel()->fetchPage(); - $this->assertContains('
assertStringContainsString('
config = $this->getMockBuilder(IConfig::class) ->disableOriginalConstructor() ->getMock(); @@ -86,6 +86,6 @@ public function testGetPanel($globalConfigs, $expectedString) { ->willReturn($globalConfigs['auto_accept_trusted']); $templateHtml = $this->sharingPersonalPanel->getPanel()->fetchPage(); - $this->assertContains($expectedString, $templateHtml); + $this->assertStringContainsString($expectedString, $templateHtml); } } diff --git a/apps/federatedfilesharing/tests/TestCase.php b/apps/federatedfilesharing/tests/TestCase.php index 61cde056f386..eff7d0b20cc9 100644 --- a/apps/federatedfilesharing/tests/TestCase.php +++ b/apps/federatedfilesharing/tests/TestCase.php @@ -39,7 +39,7 @@ abstract class TestCase extends \Test\TestCase { const TEST_FILES_SHARING_API_USER1 = "test-share-user1"; const TEST_FILES_SHARING_API_USER2 = "test-share-user2"; - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { parent::setUpBeforeClass(); // reset backend @@ -47,7 +47,7 @@ public static function setUpBeforeClass() { \OC::$server->getGroupManager()->clearBackends(); } - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->createUser(self::TEST_FILES_SHARING_API_USER1, self::TEST_FILES_SHARING_API_USER1); @@ -57,7 +57,7 @@ protected function setUp() { self::loginHelper(self::TEST_FILES_SHARING_API_USER1); } - public static function tearDownAfterClass() { + public static function tearDownAfterClass(): void { // cleanup users $user = \OC::$server->getUserManager()->get(self::TEST_FILES_SHARING_API_USER1); if ($user !== null) { diff --git a/apps/federatedfilesharing/tests/TokenHandlerTest.php b/apps/federatedfilesharing/tests/TokenHandlerTest.php index 5c404210a962..9037f5711562 100644 --- a/apps/federatedfilesharing/tests/TokenHandlerTest.php +++ b/apps/federatedfilesharing/tests/TokenHandlerTest.php @@ -37,7 +37,7 @@ class TokenHandlerTest extends \Test\TestCase { /** @var int */ private $expectedTokenLength = 15; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->secureRandom = $this->createMock('OCP\Security\ISecureRandom'); diff --git a/apps/federation/tests/API/OCSAuthAPITest.php b/apps/federation/tests/API/OCSAuthAPITest.php index c3b73c067525..ad406075546e 100644 --- a/apps/federation/tests/API/OCSAuthAPITest.php +++ b/apps/federation/tests/API/OCSAuthAPITest.php @@ -56,7 +56,7 @@ class OCSAuthAPITest extends TestCase { /** @var OCSAuthAPIController */ private $ocsAuthApi; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->createMock(IRequest::class); diff --git a/apps/federation/tests/BackgroundJob/GetSharedSecretTest.php b/apps/federation/tests/BackgroundJob/GetSharedSecretTest.php index 2899c7f01ba7..c000df5540ca 100644 --- a/apps/federation/tests/BackgroundJob/GetSharedSecretTest.php +++ b/apps/federation/tests/BackgroundJob/GetSharedSecretTest.php @@ -67,7 +67,7 @@ class GetSharedSecretTest extends TestCase { /** @var GetSharedSecret */ private $getSharedSecret; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->httpClient = $this->createMock('OCP\Http\Client\IClient'); diff --git a/apps/federation/tests/BackgroundJob/RequestSharedSecretTest.php b/apps/federation/tests/BackgroundJob/RequestSharedSecretTest.php index 6681dd4f28ce..b705f2174f80 100644 --- a/apps/federation/tests/BackgroundJob/RequestSharedSecretTest.php +++ b/apps/federation/tests/BackgroundJob/RequestSharedSecretTest.php @@ -56,7 +56,7 @@ class RequestSharedSecretTest extends TestCase { /** @var RequestSharedSecret */ private $requestSharedSecret; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->httpClient = $this->createMock('OCP\Http\Client\IClient'); diff --git a/apps/federation/tests/Controller/SettingsControllerTest.php b/apps/federation/tests/Controller/SettingsControllerTest.php index 9086409e405d..8df1bdc7e811 100644 --- a/apps/federation/tests/Controller/SettingsControllerTest.php +++ b/apps/federation/tests/Controller/SettingsControllerTest.php @@ -40,7 +40,7 @@ class SettingsControllerTest extends TestCase { /** @var \PHPUnit\Framework\MockObject\MockObject | \OCA\Federation\TrustedServers */ private $trustedServers; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->createMock('OCP\IRequest'); @@ -79,12 +79,13 @@ public function testAddServer() { /** * @dataProvider checkServerFails - * @expectedException \OC\HintException * * @param bool $isTrustedServer * @param bool $isOwnCloud */ public function testAddServerFail($isTrustedServer, $isOwnCloud) { + $this->expectException(\OC\HintException::class); + $this->trustedServers ->expects($this->any()) ->method('isTrustedServer') @@ -126,12 +127,13 @@ public function testCheckServer() { /** * @dataProvider checkServerFails - * @expectedException \OC\HintException * * @param bool $isTrustedServer * @param bool $isOwnCloud */ public function testCheckServerFail($isTrustedServer, $isOwnCloud) { + $this->expectException(\OC\HintException::class); + $this->trustedServers ->expects($this->any()) ->method('isTrustedServer') diff --git a/apps/federation/tests/DbHandlerTest.php b/apps/federation/tests/DbHandlerTest.php index 8ad1bc06ebd4..78754070f579 100644 --- a/apps/federation/tests/DbHandlerTest.php +++ b/apps/federation/tests/DbHandlerTest.php @@ -46,7 +46,7 @@ class DbHandlerTest extends TestCase { /** @var string */ private $dbTable = 'trusted_servers'; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); @@ -62,7 +62,7 @@ public function setUp() { $this->assertEmpty($result, 'we need to start with a empty trusted_servers table'); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); $query = $this->connection->getQueryBuilder()->delete($this->dbTable); $query->execute(); diff --git a/apps/federation/tests/HooksTest.php b/apps/federation/tests/HooksTest.php index 9cd0085048f0..de1f6a050159 100644 --- a/apps/federation/tests/HooksTest.php +++ b/apps/federation/tests/HooksTest.php @@ -34,7 +34,7 @@ class HooksTest extends TestCase { /** @var Hooks */ private $hooks; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->trustedServers = $this->getMockBuilder('OCA\Federation\TrustedServers') diff --git a/apps/federation/tests/Middleware/AddServerMiddlewareTest.php b/apps/federation/tests/Middleware/AddServerMiddlewareTest.php index 2e870b706286..21be6a28b7b5 100644 --- a/apps/federation/tests/Middleware/AddServerMiddlewareTest.php +++ b/apps/federation/tests/Middleware/AddServerMiddlewareTest.php @@ -43,7 +43,7 @@ class AddServerMiddlewareTest extends TestCase { /** @var \PHPUnit\Framework\MockObject\MockObject | Controller */ private $controller; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->logger = $this->createMock('OCP\ILogger'); diff --git a/apps/federation/tests/PanelTest.php b/apps/federation/tests/PanelTest.php index 48880cb413ef..c06b6b599fb2 100644 --- a/apps/federation/tests/PanelTest.php +++ b/apps/federation/tests/PanelTest.php @@ -57,7 +57,7 @@ class PanelTest extends \Test\TestCase { /** @var EventDispatcherInterface */ private $eventDispatcher; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->connection = $this->getMockBuilder(IDBConnection::class)->getMock(); $this->l = $this->getMockBuilder(IL10N::class)->getMock(); @@ -85,7 +85,7 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); $this->assertTrue($this->panel->getPriority() > -100); $this->assertTrue($this->panel->getPriority() < 100); } @@ -99,6 +99,9 @@ public function testGetPanel() { $statement->expects($this->once())->method('fetchAll')->willReturn([]); $this->connection->expects($this->once())->method('getQueryBuilder')->willReturn($queryBuilder); $templateHtml = $this->panel->getPanel()->fetchPage(); - $this->assertContains('
', $templateHtml); + $this->assertStringContainsString( + '
', + $templateHtml + ); } } diff --git a/apps/federation/tests/TrustedServersTest.php b/apps/federation/tests/TrustedServersTest.php index 387f5ee23a68..e7c88bc63e62 100644 --- a/apps/federation/tests/TrustedServersTest.php +++ b/apps/federation/tests/TrustedServersTest.php @@ -68,7 +68,7 @@ class TrustedServersTest extends TestCase { /** @var \PHPUnit\Framework\MockObject\MockObject | EventDispatcherInterface */ private $dispatcher; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->dbHandler = $this->getMockBuilder('\OCA\Federation\DbHandler') @@ -302,10 +302,11 @@ public function dataTestIsOwnCloudServer() { } /** - * @expectedException \Exception - * @expectedExceptionMessage simulated exception */ public function testIsOwnCloudServerFail() { + $this->expectException(\Exception::class); + $this->expectExceptionMessage('simulated exception'); + $server = 'server1'; $this->httpClientService->expects($this->once())->method('newClient') @@ -335,10 +336,11 @@ public function dataTestCheckOwnCloudVersion() { /** * @dataProvider dataTestCheckOwnCloudVersionTooLow - * @expectedException \OC\HintException - * @expectedExceptionMessage Remote server version is too low. ownCloud 9.0 is required. */ public function testCheckOwnCloudVersionTooLow($status) { + $this->expectException(\OC\HintException::class); + $this->expectExceptionMessage('Remote server version is too low. ownCloud 9.0 is required.'); + $this->invokePrivate($this->trustedServers, 'checkOwnCloudVersion', [$status]); } diff --git a/apps/files/tests/ActivityHelperTest.php b/apps/files/tests/ActivityHelperTest.php index e2c04ea276e8..d8037f854a58 100644 --- a/apps/files/tests/ActivityHelperTest.php +++ b/apps/files/tests/ActivityHelperTest.php @@ -52,7 +52,7 @@ class ActivityHelperTest extends \Test\TestCase { */ private $user; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->tags = $this->createMock(ITags::class); @@ -73,19 +73,21 @@ protected function setUp() { } /** - * @expectedException \RuntimeException - * @expectedExceptionMessage No favorites */ public function testGetFavoriteFilePathsNoFavorites() { + $this->expectException(\RuntimeException::class); + $this->expectExceptionMessage('No favorites'); + $this->tags->method('getFavorites')->willReturn([]); $this->helper->getFavoriteFilePaths($this->user); } /** - * @expectedException \RuntimeException - * @expectedExceptionMessage Too many favorites */ public function testGetFavoriteFilePathsTooManyFavorites() { + $this->expectException(\RuntimeException::class); + $this->expectExceptionMessage('Too many favorites'); + $tooManyFavorites = []; for ($i = 0; $i < ActivityHelper::FAVORITE_LIMIT + 1; $i++) { $tooManyFavorites[] = []; @@ -118,10 +120,11 @@ public function testGetFavoriteFilePaths() { } /** - * @expectedException \RuntimeException - * @expectedExceptionMessage No favorites */ public function testGetFavoriteFilePathsMissingFolder() { + $this->expectException(\RuntimeException::class); + $this->expectExceptionMessage('No favorites'); + $userFolder = \OC::$server->getUserFolder(); $aFolder = $userFolder->newFolder('x'); diff --git a/apps/files/tests/ActivityTest.php b/apps/files/tests/ActivityTest.php index 3206fe0db97b..a68b8fca4a66 100644 --- a/apps/files/tests/ActivityTest.php +++ b/apps/files/tests/ActivityTest.php @@ -55,7 +55,7 @@ class ActivityTest extends TestCase { /** @var \OCA\Files\Activity */ protected $activityExtension; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->request = $this->getMockBuilder('OCP\IRequest') @@ -113,7 +113,7 @@ protected function setUp() { public function testNotificationTypes() { $result = $this->activityExtension->getNotificationTypes('en'); - $this->assertInternalType('array', $result, 'Asserting getNotificationTypes() returns an array'); + $this->assertIsArray($result, 'Asserting getNotificationTypes() returns an array'); $this->assertCount(5, $result); $this->assertArrayHasKey(Activity::TYPE_SHARE_CREATED, $result); $this->assertArrayHasKey(Activity::TYPE_SHARE_CHANGED, $result); @@ -124,7 +124,7 @@ public function testNotificationTypes() { public function testDefaultTypes() { $result = $this->activityExtension->getDefaultTypes('stream'); - $this->assertInternalType('array', $result, 'Asserting getDefaultTypes(stream) returns an array'); + $this->assertIsArray($result, 'Asserting getDefaultTypes(stream) returns an array'); $this->assertCount(4, $result); $result = \array_flip($result); $this->assertArrayHasKey(Activity::TYPE_SHARE_CREATED, $result); diff --git a/apps/files/tests/BackgroundJob/DeleteOrphanedItemsJobTest.php b/apps/files/tests/BackgroundJob/DeleteOrphanedItemsJobTest.php index 4c00b888783c..c40a7e9ab791 100644 --- a/apps/files/tests/BackgroundJob/DeleteOrphanedItemsJobTest.php +++ b/apps/files/tests/BackgroundJob/DeleteOrphanedItemsJobTest.php @@ -37,7 +37,7 @@ class DeleteOrphanedItemsJobTest extends \Test\TestCase { /** @var \OCP\IDBConnection */ protected $connection; - protected function setup() { + protected function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); } diff --git a/apps/files/tests/BackgroundJob/ScanFilesTest.php b/apps/files/tests/BackgroundJob/ScanFilesTest.php index 6650e7be089e..50dcbb60b7d5 100644 --- a/apps/files/tests/BackgroundJob/ScanFilesTest.php +++ b/apps/files/tests/BackgroundJob/ScanFilesTest.php @@ -39,7 +39,7 @@ class ScanFilesTest extends TestCase { /** @var ScanFiles */ private $scanFiles; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->createMock('\OCP\IConfig'); diff --git a/apps/files/tests/CapabilitiesTest.php b/apps/files/tests/CapabilitiesTest.php index 54b13e4e3f0a..70af42962fe5 100644 --- a/apps/files/tests/CapabilitiesTest.php +++ b/apps/files/tests/CapabilitiesTest.php @@ -34,7 +34,7 @@ class CapabilitiesTest extends TestCase { /** @var Capabilities */ protected $capabilities; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->config = $this->createMock(IConfig::class); diff --git a/apps/files/tests/Command/DeleteOrphanedFilesTest.php b/apps/files/tests/Command/DeleteOrphanedFilesTest.php index 6524a8380064..7ead597e0755 100644 --- a/apps/files/tests/Command/DeleteOrphanedFilesTest.php +++ b/apps/files/tests/Command/DeleteOrphanedFilesTest.php @@ -52,7 +52,7 @@ class DeleteOrphanedFilesTest extends TestCase { */ private $user1; - protected function setup() { + protected function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); @@ -65,7 +65,7 @@ protected function setup() { $this->command = new DeleteOrphanedFiles($this->connection); } - protected function tearDown() { + protected function tearDown(): void { $userManager = \OC::$server->getUserManager(); $user1 = $userManager->get($this->user1); if ($user1) { diff --git a/apps/files/tests/Command/ScanTest.php b/apps/files/tests/Command/ScanTest.php index 76c1419e4243..d82b224057a9 100644 --- a/apps/files/tests/Command/ScanTest.php +++ b/apps/files/tests/Command/ScanTest.php @@ -94,7 +94,7 @@ class ScanTest extends TestCase { */ private $groupsCreated = []; - protected function setUp() { + protected function setUp(): void { if ($this->runsWithPrimaryObjectstorage()) { $this->markTestSkipped('not testing scanner as it does not make sense for primary object store'); } @@ -131,7 +131,7 @@ protected function setUp() { @\mkdir($this->dataDir . '/' . $this->scanUser1->getUID() . '/files/toscan', 0777, true); } - protected function tearDown() { + protected function tearDown(): void { foreach ($this->groupsCreated as $group) { $this->groupManager->get($group)->delete(); } @@ -156,7 +156,7 @@ public function dataInput() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function userInputData() { @@ -181,9 +181,12 @@ public function testGroupPaginationForUsers($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); //If pagination works then below assert shouldn't fail - $this->assertNotContains("Starting scan for user 1 out of $numberOfUsersInGroup", $output); + $this->assertStringNotContainsString( + "Starting scan for user 1 out of $numberOfUsersInGroup", + $output + ); } public function multipleGroupTest() { @@ -237,18 +240,18 @@ public function testMultipleGroups($input) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); if (\count($groups) === 2) { - $this->assertContains('Starting scan for user 1 out of 10 (user1)', $output); - $this->assertContains('Starting scan for user 1 out of 10 (user11)', $output); + $this->assertStringContainsString('Starting scan for user 1 out of 10 (user1)', $output); + $this->assertStringContainsString('Starting scan for user 1 out of 10 (user11)', $output); } elseif (\count($groups) === 3) { - $this->assertContains('Starting scan for user 1 out of 10 (user1)', $output); - $this->assertContains('Starting scan for user 1 out of 10 (user11)', $output); - $this->assertContains('Starting scan for user 1 out of 10 (user21)', $output); - $this->assertContains('Starting scan for user 10 out of 10 (user30)', $output); + $this->assertStringContainsString('Starting scan for user 1 out of 10 (user1)', $output); + $this->assertStringContainsString('Starting scan for user 1 out of 10 (user11)', $output); + $this->assertStringContainsString('Starting scan for user 1 out of 10 (user21)', $output); + $this->assertStringContainsString('Starting scan for user 10 out of 10 (user30)', $output); } elseif (\count($groups) === 4) { - $this->assertContains('Starting scan for user 1 out of 10 (user1)', $output); - $this->assertContains('Starting scan for user 1 out of 20 (user11)', $output); - $this->assertContains('Starting scan for user 11 out of 20 (user21)', $output); - $this->assertContains('Starting scan for user 10 out of 10 (user40)', $output); + $this->assertStringContainsString('Starting scan for user 1 out of 10 (user1)', $output); + $this->assertStringContainsString('Starting scan for user 1 out of 20 (user11)', $output); + $this->assertStringContainsString('Starting scan for user 11 out of 20 (user21)', $output); + $this->assertStringContainsString('Starting scan for user 10 out of 10 (user40)', $output); } else { $this->fail( "testMultipleGroups supports testing with 2,3, or 4 groups but the input has $groups groups" @@ -402,8 +405,8 @@ public function testScanRepairAllNoSingleUserMode() { $output = $this->commandTester->getDisplay(); - $this->assertContains('Please switch to single user mode', $output); - $this->assertContains('specify a user to repair', $output); + $this->assertStringContainsString('Please switch to single user mode', $output); + $this->assertStringContainsString('specify a user to repair', $output); $storageId = $this->getStorageId('home::' . $this->scanUser1->getUID()); $this->assertFalse($this->getFileCacheEntry($storageId, 'files/toscan')); diff --git a/apps/files/tests/Command/TransferOwnershipTest.php b/apps/files/tests/Command/TransferOwnershipTest.php index 1e4c38f94889..ee33198951c3 100644 --- a/apps/files/tests/Command/TransferOwnershipTest.php +++ b/apps/files/tests/Command/TransferOwnershipTest.php @@ -87,7 +87,7 @@ class TransferOwnershipTest extends TestCase { */ private $commandTester; - protected function setup() { + protected function setup(): void { parent::setUp(); $this->userManager = \OC::$server->getUserManager(); $this->shareManager = \OC::$server->getShareManager(); @@ -113,7 +113,7 @@ protected function setup() { ); $this->commandTester = new CommandTester($command); } - protected function tearDown() { + protected function tearDown(): void { $this->tearDownUserTrait(); $this->shareManager->userDeleted('share-receiver'); $this->shareManager->userDeleted($this->sourceUser->getUID()); @@ -178,7 +178,7 @@ public function testTransferAllFiles() { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains('Transferring files to target-user', $output); + $this->assertStringContainsString('Transferring files to target-user', $output); $sourceShares = $this->shareManager->getSharesBy($this->sourceUser->getUID(), Share::SHARE_TYPE_USER); $targetShares = $this->shareManager->getSharesBy($this->targetUser->getUID(), Share::SHARE_TYPE_USER); $this->assertCount(0, $sourceShares); @@ -209,7 +209,7 @@ public function testTransferSpecificFolder($path, $expectedSourceShareCount, $ex $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains('Transferring files to target-user', $output); + $this->assertStringContainsString('Transferring files to target-user', $output); $sourceShares = $this->shareManager->getSharesBy($this->sourceUser->getUID(), Share::SHARE_TYPE_USER); $targetShares = $this->shareManager->getSharesBy($this->targetUser->getUID(), Share::SHARE_TYPE_USER); $this->assertCount($expectedSourceShareCount, $sourceShares); diff --git a/apps/files/tests/Command/VerifyChecksumsTest.php b/apps/files/tests/Command/VerifyChecksumsTest.php index 6d49c0bfe1a1..42758a68b601 100644 --- a/apps/files/tests/Command/VerifyChecksumsTest.php +++ b/apps/files/tests/Command/VerifyChecksumsTest.php @@ -43,7 +43,7 @@ class VerifyChecksumsTest extends TestCase { */ private $testFiles; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->rootFolder = \OC::$server->getRootFolder(); @@ -190,11 +190,11 @@ public function testFilesWithBrokenChecksumsAreDisplayed() { $output = $this->cmd->getDisplay(); - $this->assertContains($file1->getInternalPath(), $output); - $this->assertContains($file2->getInternalPath(), $output); - $this->assertContains(self::BROKEN_CHECKSUM_STRING, $output); - $this->assertContains($this->testFiles[4]['expectedChecksums'](), $output); - $this->assertContains($this->testFiles[7]['expectedChecksums'](), $output); + $this->assertStringContainsString($file1->getInternalPath(), $output); + $this->assertStringContainsString($file2->getInternalPath(), $output); + $this->assertStringContainsString(self::BROKEN_CHECKSUM_STRING, $output); + $this->assertStringContainsString($this->testFiles[4]['expectedChecksums'](), $output); + $this->assertStringContainsString($this->testFiles[7]['expectedChecksums'](), $output); } /** @@ -314,8 +314,8 @@ public function testFileWithoutChecksumIsIgnored() { $this->cmd->execute([], ['verbosity' => OutputInterface::VERBOSITY_VERBOSE]); $output = $this->cmd->getDisplay(); - $this->assertContains('somefile.txt => No Checksum', $output); - $this->assertContains('Skipping', $output); + $this->assertStringContainsString('somefile.txt => No Checksum', $output); + $this->assertStringContainsString('Skipping', $output); } public function testFileInCacheButNotOnDiskIsIgnored() { @@ -329,7 +329,7 @@ public function testFileInCacheButNotOnDiskIsIgnored() { $this->cmd->execute([], ['verbosity' => OutputInterface::VERBOSITY_VERBOSE]); $output = $this->cmd->getDisplay(); - $this->assertContains('x-file.txt => File is in file-cache but doesn\'t exist on storage/disk', $output); + $this->assertStringContainsString('x-file.txt => File is in file-cache but doesn\'t exist on storage/disk', $output); } public function testInvalidArgs() { diff --git a/apps/files/tests/Controller/ApiControllerTest.php b/apps/files/tests/Controller/ApiControllerTest.php index 0cdf158d44ce..dfa113e43de0 100644 --- a/apps/files/tests/Controller/ApiControllerTest.php +++ b/apps/files/tests/Controller/ApiControllerTest.php @@ -59,7 +59,7 @@ class ApiControllerTest extends TestCase { /** @var \OCP\IConfig */ private $config; - public function setUp() { + public function setUp(): void { $this->request = $this->getMockBuilder('\OCP\IRequest') ->disableOriginalConstructor() ->getMock(); diff --git a/apps/files/tests/Controller/ViewControllerTest.php b/apps/files/tests/Controller/ViewControllerTest.php index 5001e9522e5c..d91016058b34 100644 --- a/apps/files/tests/Controller/ViewControllerTest.php +++ b/apps/files/tests/Controller/ViewControllerTest.php @@ -68,7 +68,7 @@ class ViewControllerTest extends TestCase { /** @var Folder | \PHPUnit\Framework\MockObject\MockObject */ private $rootFolder; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->createMock('\OCP\IRequest'); $this->urlGenerator = $this->createMock('\OCP\IURLGenerator'); diff --git a/apps/files/tests/Service/TagServiceTest.php b/apps/files/tests/Service/TagServiceTest.php index 8cf7bb291255..3497cd206172 100644 --- a/apps/files/tests/Service/TagServiceTest.php +++ b/apps/files/tests/Service/TagServiceTest.php @@ -58,7 +58,7 @@ class TagServiceTest extends \Test\TestCase { */ private $tagManager; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->user = $this->getUniqueID('user'); $user = $this->createUser($this->user, 'test'); @@ -81,7 +81,7 @@ protected function setUp() { ); } - protected function tearDown() { + protected function tearDown(): void { \OC_User::setUserId(''); parent::tearDown(); } diff --git a/apps/files_external/tests/Controller/GlobalStoragesControllerTest.php b/apps/files_external/tests/Controller/GlobalStoragesControllerTest.php index 2d4e2771c64c..d99b1c7b2856 100644 --- a/apps/files_external/tests/Controller/GlobalStoragesControllerTest.php +++ b/apps/files_external/tests/Controller/GlobalStoragesControllerTest.php @@ -28,7 +28,7 @@ use OCP\Files\External\IStoragesBackendService; class GlobalStoragesControllerTest extends StoragesControllerTest { - public function setUp() { + public function setUp(): void { parent::setUp(); $this->service = $this->createMock('\OCP\Files\External\Service\IGlobalStoragesService'); diff --git a/apps/files_external/tests/Controller/StoragesControllerTest.php b/apps/files_external/tests/Controller/StoragesControllerTest.php index 001a3b38994a..763b460e0cee 100644 --- a/apps/files_external/tests/Controller/StoragesControllerTest.php +++ b/apps/files_external/tests/Controller/StoragesControllerTest.php @@ -41,12 +41,12 @@ abstract class StoragesControllerTest extends \Test\TestCase { */ protected $service; - public function setUp() { + public function setUp(): void { \OC_Mount_Config::$skipTest = true; \OC::$server->getSystemConfig()->setValue('files_external_allow_create_new_local', true); } - public function tearDown() { + public function tearDown(): void { \OC_Mount_Config::$skipTest = false; \OC::$server->getSystemConfig()->setValue('files_external_allow_create_new_local', false); } diff --git a/apps/files_external/tests/Controller/UserStoragesControllerTest.php b/apps/files_external/tests/Controller/UserStoragesControllerTest.php index cd0b9a6af915..ce36f407ff12 100644 --- a/apps/files_external/tests/Controller/UserStoragesControllerTest.php +++ b/apps/files_external/tests/Controller/UserStoragesControllerTest.php @@ -36,7 +36,7 @@ class UserStoragesControllerTest extends StoragesControllerTest { */ private $oldAllowedBackends; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->service = $this->createMock('\OCP\Files\External\Service\IUserStoragesService'); diff --git a/apps/files_external/tests/Panels/AdminTest.php b/apps/files_external/tests/Panels/AdminTest.php index a1d2f31547af..12c87a27d387 100644 --- a/apps/files_external/tests/Panels/AdminTest.php +++ b/apps/files_external/tests/Panels/AdminTest.php @@ -43,7 +43,7 @@ class AdminTest extends \Test\TestCase { /** @var IConfig */ private $config; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->backendService = $this->createMock(IStoragesBackendService::class); $this->storagesService = $this->createMock(IGlobalStoragesService::class); @@ -62,7 +62,7 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); $this->assertTrue($this->panel->getPriority() > -100); $this->assertTrue($this->panel->getPriority() < 100); } diff --git a/apps/files_external/tests/Panels/PersonalTest.php b/apps/files_external/tests/Panels/PersonalTest.php index 0f00813b3105..2414de1f328c 100644 --- a/apps/files_external/tests/Panels/PersonalTest.php +++ b/apps/files_external/tests/Panels/PersonalTest.php @@ -43,7 +43,7 @@ class PersonalTest extends \Test\TestCase { /** @var Manager */ private $encManager; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->backendService = $this->createMock(IStoragesBackendService::class); $this->storagesService = $this->createMock(IUserStoragesService::class); @@ -62,7 +62,7 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); $this->assertTrue($this->panel->getPriority() > -100); $this->assertTrue($this->panel->getPriority() < 100); } diff --git a/apps/files_external/tests/Storage/GoogleTest.php b/apps/files_external/tests/Storage/GoogleTest.php index 0d93506f6377..7b8b9b565d8c 100644 --- a/apps/files_external/tests/Storage/GoogleTest.php +++ b/apps/files_external/tests/Storage/GoogleTest.php @@ -41,7 +41,7 @@ class GoogleTest extends \Test\Files\Storage\Storage { private $config; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->config = include('files_external/tests/config.php'); @@ -53,7 +53,7 @@ protected function setUp() { $this->instance = new Google($this->config['google']); } - protected function tearDown() { + protected function tearDown(): void { if ($this->instance) { $this->instance->rmdir('/'); } diff --git a/apps/files_external/tests/Storage/OwncloudTest.php b/apps/files_external/tests/Storage/OwncloudTest.php index 20f7876f4b42..5900e443ec3c 100644 --- a/apps/files_external/tests/Storage/OwncloudTest.php +++ b/apps/files_external/tests/Storage/OwncloudTest.php @@ -37,7 +37,7 @@ class OwncloudTest extends \Test\Files\Storage\Storage { private $config; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $id = $this->getUniqueID(); @@ -50,7 +50,7 @@ protected function setUp() { $this->instance->mkdir('/'); } - protected function tearDown() { + protected function tearDown(): void { if ($this->instance) { $this->instance->rmdir('/'); } diff --git a/apps/files_external/tests/Storage/SFTP_KeyTest.php b/apps/files_external/tests/Storage/SFTP_KeyTest.php index 706c5b7a7853..b7a23f4e7026 100644 --- a/apps/files_external/tests/Storage/SFTP_KeyTest.php +++ b/apps/files_external/tests/Storage/SFTP_KeyTest.php @@ -37,7 +37,7 @@ class SFTP_KeyTest extends \Test\Files\Storage\Storage { private $config; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $id = $this->getUniqueID(); @@ -51,7 +51,7 @@ protected function setUp() { $this->instance->mkdir('/'); } - protected function tearDown() { + protected function tearDown(): void { if ($this->instance) { $this->instance->rmdir('/'); } @@ -60,9 +60,10 @@ protected function tearDown() { } /** - * @expectedException InvalidArgumentException */ public function testInvalidAddressShouldThrowException() { + $this->expectException(\InvalidArgumentException::class); + // I'd use example.com for this, but someone decided to break the spec and make it resolve $this->instance->assertHostAddressValid('notarealaddress...'); } @@ -72,23 +73,26 @@ public function testValidAddressShouldPass() { } /** - * @expectedException InvalidArgumentException */ public function testNegativePortNumberShouldThrowException() { + $this->expectException(\InvalidArgumentException::class); + $this->instance->assertPortNumberValid('-1'); } /** - * @expectedException InvalidArgumentException */ public function testNonNumericalPortNumberShouldThrowException() { + $this->expectException(\InvalidArgumentException::class); + $this->instance->assertPortNumberValid('a'); } /** - * @expectedException InvalidArgumentException */ public function testHighPortNumberShouldThrowException() { + $this->expectException(\InvalidArgumentException::class); + $this->instance->assertPortNumberValid('65536'); } diff --git a/apps/files_external/tests/Storage/SftpTest.php b/apps/files_external/tests/Storage/SftpTest.php index 6f48366264b2..a1813ba3a2be 100644 --- a/apps/files_external/tests/Storage/SftpTest.php +++ b/apps/files_external/tests/Storage/SftpTest.php @@ -44,7 +44,7 @@ class SftpTest extends \Test\Files\Storage\Storage { private $config; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $id = $this->getUniqueID(); @@ -57,7 +57,7 @@ protected function setUp() { $this->instance->mkdir('/'); } - protected function tearDown() { + protected function tearDown(): void { if ($this->instance) { $this->instance->rmdir('/'); } diff --git a/apps/files_external/tests/Storage/SmbTest.php b/apps/files_external/tests/Storage/SmbTest.php index 271271503352..7a8d26578411 100644 --- a/apps/files_external/tests/Storage/SmbTest.php +++ b/apps/files_external/tests/Storage/SmbTest.php @@ -37,7 +37,7 @@ * @package OCA\Files_External\Tests\Storage */ class SmbTest extends \Test\Files\Storage\Storage { - protected function setUp() { + protected function setUp(): void { parent::setUp(); $id = $this->getUniqueID(); $config = include 'files_external/tests/config.smb.php'; @@ -52,7 +52,7 @@ protected function setUp() { $this->assertTrue($this->instance->mkdir('/'), 'Failed to create a root dir'); } - protected function tearDown() { + protected function tearDown(): void { if ($this->instance) { $this->instance->rmdir(''); // force disconnect of the client diff --git a/apps/files_external/tests/Storage/WebdavTest.php b/apps/files_external/tests/Storage/WebdavTest.php index b22c7615cf94..daec691331d3 100644 --- a/apps/files_external/tests/Storage/WebdavTest.php +++ b/apps/files_external/tests/Storage/WebdavTest.php @@ -36,7 +36,7 @@ * @package OCA\Files_External\Tests\Storage */ class WebdavTest extends \Test\Files\Storage\Storage { - protected function setUp() { + protected function setUp(): void { parent::setUp(); $id = $this->getUniqueID(); @@ -52,7 +52,7 @@ protected function setUp() { $this->instance->mkdir('/'); } - protected function tearDown() { + protected function tearDown(): void { if ($this->instance) { $this->instance->rmdir('/'); } diff --git a/apps/files_sharing/tests/API/ShareesTest.php b/apps/files_sharing/tests/API/ShareesTest.php index dca172ef5998..81085b455f39 100644 --- a/apps/files_sharing/tests/API/ShareesTest.php +++ b/apps/files_sharing/tests/API/ShareesTest.php @@ -81,7 +81,7 @@ class ShareesTest extends TestCase { /** @var UserSearch|\PHPUnit\Framework\MockObject\MockObject */ protected $userSearch; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userManager = $this->getMockBuilder(IUserManager::class) @@ -1912,9 +1912,10 @@ public function dataTestSplitUserRemoteError() { * @dataProvider dataTestSplitUserRemoteError * * @param string $id - * @expectedException \Exception */ public function testSplitUserRemoteError($id) { + $this->expectException(\Exception::class); + $this->sharees->splitUserRemote($id); } diff --git a/apps/files_sharing/tests/ActivityTest.php b/apps/files_sharing/tests/ActivityTest.php index 95c2a57d8e34..f7494ea4d6b8 100644 --- a/apps/files_sharing/tests/ActivityTest.php +++ b/apps/files_sharing/tests/ActivityTest.php @@ -40,7 +40,7 @@ class ActivityTest extends TestCase { */ private $activity; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->activity = new Activity( $this->getMockBuilder('OCP\L10N\IFactory') diff --git a/apps/files_sharing/tests/ApiTest.php b/apps/files_sharing/tests/ApiTest.php index 10a55f308b06..b498cb3c2300 100644 --- a/apps/files_sharing/tests/ApiTest.php +++ b/apps/files_sharing/tests/ApiTest.php @@ -52,7 +52,7 @@ class ApiTest extends TestCase { /** @var string */ private $subsubfolder; - protected function setUp() { + protected function setUp(): void { parent::setUp(); \OC::$server->getAppConfig()->setValue('core', 'shareapi_exclude_groups', 'no'); @@ -75,7 +75,7 @@ protected function setUp() { $this->userFolder = \OC::$server->getUserFolder(self::TEST_FILES_SHARING_API_USER1); } - protected function tearDown() { + protected function tearDown(): void { if ($this->view instanceof \OC\Files\View) { $this->view->unlink($this->filename); $this->view->deleteAll($this->folder); @@ -245,7 +245,7 @@ public function testCreateShareLink() { $data = $result->getData(); $this->assertEquals(1, $data['permissions']); $this->assertEmpty($data['expiration']); - $this->assertInternalType('string', $data['token']); + $this->assertIsString($data['token']); // check for correct link $url = \OC::$server->getURLGenerator()->getAbsoluteURL('/index.php/s/' . $data['token']); @@ -281,7 +281,7 @@ public function testCreateShareLinkPublicUpload() { $data['permissions'] ); $this->assertEmpty($data['expiration']); - $this->assertInternalType('string', $data['token']); + $this->assertIsString($data['token']); // check for correct link $url = \OC::$server->getURLGenerator()->getAbsoluteURL('/index.php/s/' . $data['token']); @@ -497,7 +497,7 @@ public function testPublicLinkUrl() { $data = $result->getData(); // check if we have a token - $this->assertInternalType('string', $data['token']); + $this->assertIsString($data['token']); $id = $data['id']; // check for correct link @@ -1361,9 +1361,10 @@ public function testShareStorageMountPoint() { \OC_Hook::clear('OC_Filesystem', 'post_initMountPoints', '\OCA\Files_Sharing\Tests\ApiTest', 'initTestMountPointsHook'); } /** - * @expectedException \Exception */ public function testShareNonExisting() { + $this->expectException(\Exception::class); + self::loginHelper(self::TEST_FILES_SHARING_API_USER1); $id = PHP_INT_MAX - 1; @@ -1371,9 +1372,10 @@ public function testShareNonExisting() { } /** - * @expectedException \Exception */ public function testShareNotOwner() { + $this->expectException(\Exception::class); + self::loginHelper(self::TEST_FILES_SHARING_API_USER2); \OC\Files\Filesystem::file_put_contents('foo.txt', 'bar'); $info = \OC\Files\Filesystem::getFileInfo('foo.txt'); @@ -1413,7 +1415,7 @@ public function testDefaultExpireDate() { $this->assertInstanceOf(\OC\Files\FileInfo::class, $info); $result = Share::shareItem('file', $info->getId(), Share::SHARE_TYPE_LINK, null, Constants::PERMISSION_READ); - $this->assertInternalType('string', $result); + $this->assertIsString($result); $result = Share::shareItem('file', $info->getId(), Share::SHARE_TYPE_USER, self::TEST_FILES_SHARING_API_USER2, 31); $this->assertTrue($result); @@ -1433,7 +1435,7 @@ public function testDefaultExpireDate() { // now the link share should expire because of enforced default expire date // the user share should still exist $result = Share::getItemShared('file', $info->getId()); - $this->assertInternalType('array', $result); + $this->assertIsArray($result); $this->assertCount(1, $result); $share = \reset($result); $this->assertSame(Share::SHARE_TYPE_USER, $share['share_type']); @@ -1480,7 +1482,7 @@ public function testPublicLinkExpireDate($date, $valid) { $this->assertTrue($result->succeeded()); $data = $result->getData(); - $this->assertInternalType('string', $data['token']); + $this->assertIsString($data['token']); $this->assertEquals($date, \substr($data['expiration'], 0, 10)); // check for correct link @@ -1514,7 +1516,7 @@ public function testCreatePublicLinkExpireDateValid() { $this->assertTrue($result->succeeded()); $data = $result->getData(); - $this->assertInternalType('string', $data['token']); + $this->assertIsString($data['token']); $this->assertEquals($date->format('Y-m-d') . ' 00:00:00', $data['expiration']); // check for correct link diff --git a/apps/files_sharing/tests/BackendTest.php b/apps/files_sharing/tests/BackendTest.php index 704ab2d5f755..eb31b14c876a 100644 --- a/apps/files_sharing/tests/BackendTest.php +++ b/apps/files_sharing/tests/BackendTest.php @@ -37,7 +37,7 @@ class BackendTest extends TestCase { public $subfolder; public $subsubfolder; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->folder = self::TEST_FOLDER_NAME; @@ -56,7 +56,7 @@ protected function setUp() { $this->view->file_put_contents($this->folder . $this->subfolder . $this->subsubfolder . $this->filename, $this->data); } - protected function tearDown() { + protected function tearDown(): void { if ($this->view) { $this->view->unlink($this->filename); $this->view->deleteAll($this->folder); diff --git a/apps/files_sharing/tests/CacheTest.php b/apps/files_sharing/tests/CacheTest.php index 7fe77f4d96a9..42987a908858 100644 --- a/apps/files_sharing/tests/CacheTest.php +++ b/apps/files_sharing/tests/CacheTest.php @@ -58,7 +58,7 @@ class CacheTest extends TestCase { /** @var \OCP\Share\IManager */ protected $shareManager; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->shareManager = \OC::$server->getShareManager(); @@ -123,7 +123,7 @@ protected function setUp() { $this->sharedCache = $this->sharedStorage->getCache(); } - protected function tearDown() { + protected function tearDown(): void { if ($this->sharedCache) { $this->sharedCache->clear(); } diff --git a/apps/files_sharing/tests/CapabilitiesTest.php b/apps/files_sharing/tests/CapabilitiesTest.php index b2f76cd30e09..0ddf6279b630 100644 --- a/apps/files_sharing/tests/CapabilitiesTest.php +++ b/apps/files_sharing/tests/CapabilitiesTest.php @@ -43,7 +43,7 @@ class CapabilitiesTest extends \Test\TestCase { /** * */ - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userSearch = $this->getMockBuilder(\OCP\Util\UserSearch::class) ->disableOriginalConstructor() @@ -116,7 +116,7 @@ public function testNoLinkSharing() { ['core', 'shareapi_allow_links', 'yes', 'no'], ]; $result = $this->getResults($map); - $this->assertInternalType('array', $result['public']); + $this->assertIsArray($result['public']); $this->assertFalse($result['public']['enabled']); } @@ -149,7 +149,7 @@ public function testOnlyLinkSharing() { ['core', 'shareapi_allow_links', 'yes', 'yes'], ]; $result = $this->getResults($map); - $this->assertInternalType('array', $result['public']); + $this->assertIsArray($result['public']); $this->assertTrue($result['public']['enabled']); } @@ -218,7 +218,7 @@ public function testLinkNoExpireDate() { ]; $result = $this->getResults($map); $this->assertArrayHasKey('expire_date', $result['public']); - $this->assertInternalType('array', $result['public']['expire_date']); + $this->assertIsArray($result['public']['expire_date']); $this->assertFalse($result['public']['expire_date']['enabled']); } @@ -232,7 +232,7 @@ public function testLinkExpireDate() { ]; $result = $this->getResults($map); $this->assertArrayHasKey('expire_date', $result['public']); - $this->assertInternalType('array', $result['public']['expire_date']); + $this->assertIsArray($result['public']['expire_date']); $this->assertTrue($result['public']['expire_date']['enabled']); $this->assertArrayHasKey('days', $result['public']['expire_date']); $this->assertFalse($result['public']['expire_date']['enforced']); @@ -247,7 +247,7 @@ public function testLinkExpireDateEnforced() { ]; $result = $this->getResults($map); $this->assertArrayHasKey('expire_date', $result['public']); - $this->assertInternalType('array', $result['public']['expire_date']); + $this->assertIsArray($result['public']['expire_date']); $this->assertTrue($result['public']['expire_date']['enforced']); } diff --git a/apps/files_sharing/tests/Command/CleanupRemoteStoragesTest.php b/apps/files_sharing/tests/Command/CleanupRemoteStoragesTest.php index b7c707db7734..3b359e9fbe2e 100644 --- a/apps/files_sharing/tests/Command/CleanupRemoteStoragesTest.php +++ b/apps/files_sharing/tests/Command/CleanupRemoteStoragesTest.php @@ -54,7 +54,7 @@ class CleanupRemoteStoragesTest extends TestCase { ['notExistingId' => 'shared::c34568c143cdac7d2f06e0800b5280f9', 'share_token' => 'f2c69dad1dc0649f26976fd210fc62e7', 'remote' => 'https://hostname.tld/owncloud7', 'user' => 'user7'], ]; - protected function setup() { + protected function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); @@ -107,7 +107,7 @@ protected function setup() { $this->command = new CleanupRemoteStorages($this->connection); } - public function tearDown() { + public function tearDown(): void { $storageQuery = \OC::$server->getDatabaseConnection()->getQueryBuilder(); $storageQuery->delete('storages') ->where($storageQuery->expr()->eq('id', $storageQuery->createParameter('id'))); @@ -130,7 +130,7 @@ public function tearDown() { } } - return parent::tearDown(); + parent::tearDown(); } private function doesStorageExist($numericId) { diff --git a/apps/files_sharing/tests/Controller/NotificationControllerTest.php b/apps/files_sharing/tests/Controller/NotificationControllerTest.php index afcf67aed314..bf29e857b5b3 100644 --- a/apps/files_sharing/tests/Controller/NotificationControllerTest.php +++ b/apps/files_sharing/tests/Controller/NotificationControllerTest.php @@ -51,7 +51,7 @@ class NotificationControllerTest extends TestCase { /** @var NotificationController $notificationController */ private $notificationController; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->request = $this->createMock(IRequest::class); $this->mailNotifications = $this->createMock(MailNotifications::class); diff --git a/apps/files_sharing/tests/Controller/PersonalSettingsControllerTest.php b/apps/files_sharing/tests/Controller/PersonalSettingsControllerTest.php index b023725a0a5b..42e2244b287c 100644 --- a/apps/files_sharing/tests/Controller/PersonalSettingsControllerTest.php +++ b/apps/files_sharing/tests/Controller/PersonalSettingsControllerTest.php @@ -44,7 +44,7 @@ class PersonalSettingsControllerTest extends TestCase { /** @var PersonalSettingsController $personalSettingsController */ private $personalSettingsController; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->config = $this->getMockBuilder(IConfig::class) ->disableOriginalConstructor() diff --git a/apps/files_sharing/tests/Controller/Share20OcsControllerTest.php b/apps/files_sharing/tests/Controller/Share20OcsControllerTest.php index f1708e61a6be..c4e21cd694b8 100644 --- a/apps/files_sharing/tests/Controller/Share20OcsControllerTest.php +++ b/apps/files_sharing/tests/Controller/Share20OcsControllerTest.php @@ -104,7 +104,7 @@ class Share20OcsControllerTest extends TestCase { /** @var IConfig */ private $config; - protected function setUp() { + protected function setUp(): void { $this->shareManager = $this->getMockBuilder(IManager::class) ->disableOriginalConstructor() ->getMock(); @@ -162,7 +162,7 @@ protected function setUp() { ); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); } diff --git a/apps/files_sharing/tests/Controllers/ExternalShareControllerTest.php b/apps/files_sharing/tests/Controllers/ExternalShareControllerTest.php index 34ac1c625d80..d54c637b2285 100644 --- a/apps/files_sharing/tests/Controllers/ExternalShareControllerTest.php +++ b/apps/files_sharing/tests/Controllers/ExternalShareControllerTest.php @@ -44,7 +44,7 @@ class ExternalShareControllerTest extends \Test\TestCase { /** @var IClientService */ private $clientService; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->getMockBuilder('\\OCP\\IRequest') ->disableOriginalConstructor()->getMock(); diff --git a/apps/files_sharing/tests/Controllers/ShareControllerTest.php b/apps/files_sharing/tests/Controllers/ShareControllerTest.php index a8e49f9707b5..91135223d2b6 100644 --- a/apps/files_sharing/tests/Controllers/ShareControllerTest.php +++ b/apps/files_sharing/tests/Controllers/ShareControllerTest.php @@ -74,7 +74,7 @@ class ShareControllerTest extends \Test\TestCase { /** @var EventDispatcher | \PHPUnit\Framework\MockObject\MockObject */ private $eventDispatcher; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->appName = 'files_sharing'; @@ -112,7 +112,7 @@ protected function setUp() { $this->loginAsUser($this->user); } - protected function tearDown() { + protected function tearDown(): void { \OC_Util::tearDownFS(); \OC_User::setUserId(''); Filesystem::tearDown(); @@ -438,9 +438,10 @@ public function testShowShare() { } /** - * @expectedException \OCP\Files\NotFoundException */ public function testShowShareInvalid() { + $this->expectException(\OCP\Files\NotFoundException::class); + $owner = $this->createMock('OCP\IUser'); $owner->method('getDisplayName')->willReturn('ownerDisplay'); $owner->method('getUID')->willReturn('ownerUID'); @@ -507,9 +508,10 @@ public function testDownloadShare() { } /** - * @expectedException \OCP\Files\NotFoundException */ public function testDownloadShareNoReadPermission() { + $this->expectException(\OCP\Files\NotFoundException::class); + $share = $this->createMock('\OCP\Share\IShare'); $share->method('getPermissions')->willReturn(\OCP\Constants::PERMISSION_CREATE); diff --git a/apps/files_sharing/tests/DeleteOrphanedSharesJobTest.php b/apps/files_sharing/tests/DeleteOrphanedSharesJobTest.php index 508b51caa1a0..f9849f200079 100644 --- a/apps/files_sharing/tests/DeleteOrphanedSharesJobTest.php +++ b/apps/files_sharing/tests/DeleteOrphanedSharesJobTest.php @@ -59,7 +59,7 @@ class DeleteOrphanedSharesJobTest extends \Test\TestCase { */ private $user2; - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { $appManager = \OC::$server->getAppManager(); self::$trashBinStatus = $appManager->isEnabledForUser('files_trashbin'); $appManager->disableApp('files_trashbin'); @@ -68,13 +68,13 @@ public static function setUpBeforeClass() { \OC\Files\Filesystem::getLoader()->removeStorageWrapper('oc_trashbin'); } - public static function tearDownAfterClass() { + public static function tearDownAfterClass(): void { if (self::$trashBinStatus) { \OC::$server->getAppManager()->enableApp('files_trashbin'); } } - protected function setup() { + protected function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); @@ -93,7 +93,7 @@ protected function setup() { $this->job = new DeleteOrphanedSharesJob(); } - protected function tearDown() { + protected function tearDown(): void { $this->connection->executeUpdate('DELETE FROM `*PREFIX*share`'); $userManager = \OC::$server->getUserManager(); diff --git a/apps/files_sharing/tests/ExpireSharesJobTest.php b/apps/files_sharing/tests/ExpireSharesJobTest.php index 0091cd85fb17..ec42ec220cd1 100644 --- a/apps/files_sharing/tests/ExpireSharesJobTest.php +++ b/apps/files_sharing/tests/ExpireSharesJobTest.php @@ -54,7 +54,7 @@ class ExpireSharesJobTest extends \Test\TestCase { */ private $user2; - protected function setup() { + protected function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); @@ -73,7 +73,7 @@ protected function setup() { $this->job = new ExpireSharesJob(); } - protected function tearDown() { + protected function tearDown(): void { $this->connection->executeUpdate('DELETE FROM `*PREFIX*share`'); $userManager = \OC::$server->getUserManager(); diff --git a/apps/files_sharing/tests/External/CacheTest.php b/apps/files_sharing/tests/External/CacheTest.php index 65e061cff2ca..b10d7f659205 100644 --- a/apps/files_sharing/tests/External/CacheTest.php +++ b/apps/files_sharing/tests/External/CacheTest.php @@ -49,7 +49,7 @@ class CacheTest extends TestCase { */ private $remoteUser; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->remoteUser = $this->getUniqueID('remoteuser'); @@ -76,7 +76,7 @@ protected function setUp() { ); } - protected function tearDown() { + protected function tearDown(): void { if ($this->cache) { $this->cache->clear(); } diff --git a/apps/files_sharing/tests/External/ManagerTest.php b/apps/files_sharing/tests/External/ManagerTest.php index e4fd6b4912d8..a55f05b29ccb 100644 --- a/apps/files_sharing/tests/External/ManagerTest.php +++ b/apps/files_sharing/tests/External/ManagerTest.php @@ -62,7 +62,7 @@ class ManagerTest extends TestCase { private $user; private $mountProvider; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->uid = $this->getUniqueID('user'); diff --git a/apps/files_sharing/tests/External/MountProviderTest.php b/apps/files_sharing/tests/External/MountProviderTest.php index 8965de004b7b..f8236452d125 100644 --- a/apps/files_sharing/tests/External/MountProviderTest.php +++ b/apps/files_sharing/tests/External/MountProviderTest.php @@ -43,7 +43,7 @@ class MountProviderTest extends TestCase { /** @var MountProvider */ private $mountProvider; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->dbConnection = $this->createMock(IDBConnection::class); $this->mountProvider = new MountProvider($this->dbConnection, function () { diff --git a/apps/files_sharing/tests/HooksTest.php b/apps/files_sharing/tests/HooksTest.php index c2bba4cf96f4..61599e1c69b9 100644 --- a/apps/files_sharing/tests/HooksTest.php +++ b/apps/files_sharing/tests/HooksTest.php @@ -84,7 +84,7 @@ class HooksTest extends \Test\TestCase { */ private $hooks; - public function setUp() { + public function setUp(): void { $this->eventDispatcher = new EventDispatcher(); $this->urlGenerator = $this->createMock(IURLGenerator::class); $this->rootFolder = $this->createMock(IRootFolder::class); diff --git a/apps/files_sharing/tests/LockingTest.php b/apps/files_sharing/tests/LockingTest.php index a07c96c9ccf2..27357167d628 100644 --- a/apps/files_sharing/tests/LockingTest.php +++ b/apps/files_sharing/tests/LockingTest.php @@ -43,7 +43,7 @@ class LockingTest extends TestCase { private $ownerUid; private $recipientUid; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->ownerUid = $this->getUniqueID('owner_'); @@ -69,9 +69,10 @@ public function setUp() { } /** - * @expectedException \OCP\Lock\LockedException */ public function testLockAsRecipient() { + $this->expectException(\OCP\Lock\LockedException::class); + $this->loginAsUser($this->ownerUid); Filesystem::initMountPoints($this->recipientUid); diff --git a/apps/files_sharing/tests/Middleware/SharingCheckMiddlewareTest.php b/apps/files_sharing/tests/Middleware/SharingCheckMiddlewareTest.php index 4c2d1000817a..2609fd91d887 100644 --- a/apps/files_sharing/tests/Middleware/SharingCheckMiddlewareTest.php +++ b/apps/files_sharing/tests/Middleware/SharingCheckMiddlewareTest.php @@ -45,7 +45,7 @@ class SharingCheckMiddlewareTest extends \Test\TestCase { /** @var IControllerMethodReflector */ private $reflector; - protected function setUp() { + protected function setUp(): void { $this->config = $this->getMockBuilder('\OCP\IConfig') ->disableOriginalConstructor()->getMock(); $this->appManager = $this->getMockBuilder('\OCP\App\IAppManager') @@ -234,10 +234,11 @@ public function testBeforeControllerWithShareControllerWithSharingEnabled() { } /** - * @expectedException \OCP\Files\NotFoundException - * @expectedExceptionMessage Link sharing is disabled */ public function testBeforeControllerWithShareControllerWithSharingEnabledAPIDisabled() { + $this->expectException(\OCP\Files\NotFoundException::class); + $this->expectExceptionMessage('Link sharing is disabled'); + $this->appManager ->expects($this->once()) ->method('isEnabledForUser') @@ -251,10 +252,11 @@ public function testBeforeControllerWithShareControllerWithSharingEnabledAPIDisa } /** - * @expectedException \OCP\Files\NotFoundException - * @expectedExceptionMessage Sharing is disabled. */ public function testBeforeControllerWithSharingDisabled() { + $this->expectException(\OCP\Files\NotFoundException::class); + $this->expectExceptionMessage('Sharing is disabled.'); + $this->appManager ->expects($this->once()) ->method('isEnabledForUser') @@ -265,10 +267,11 @@ public function testBeforeControllerWithSharingDisabled() { } /** - * @expectedException \Exception - * @expectedExceptionMessage My Exception message */ public function testAfterExceptionWithRegularException() { + $this->expectException(\Exception::class); + $this->expectExceptionMessage('My Exception message'); + $this->sharingCheckMiddleware->afterException($this->controllerMock, 'myMethod', new \Exception('My Exception message')); } diff --git a/apps/files_sharing/tests/MigrationTest.php b/apps/files_sharing/tests/MigrationTest.php index b220d6435dfd..754bfe981a9a 100644 --- a/apps/files_sharing/tests/MigrationTest.php +++ b/apps/files_sharing/tests/MigrationTest.php @@ -42,7 +42,7 @@ class MigrationTest extends TestCase { private $table = 'share'; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); @@ -51,7 +51,7 @@ public function setUp() { $this->cleanDB(); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); $this->cleanDB(); } diff --git a/apps/files_sharing/tests/MountProviderTest.php b/apps/files_sharing/tests/MountProviderTest.php index 4766ebd71212..20a26ca6132c 100644 --- a/apps/files_sharing/tests/MountProviderTest.php +++ b/apps/files_sharing/tests/MountProviderTest.php @@ -54,7 +54,7 @@ class MountProviderTest extends \Test\TestCase { /** @var ILogger | \PHPUnit\Framework\MockObject\MockObject */ private $logger; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->createMock('OCP\IConfig'); diff --git a/apps/files_sharing/tests/NotifierTest.php b/apps/files_sharing/tests/NotifierTest.php index b39dd5bdc9a2..3dd1e480a086 100644 --- a/apps/files_sharing/tests/NotifierTest.php +++ b/apps/files_sharing/tests/NotifierTest.php @@ -55,7 +55,7 @@ class NotifierTest extends \Test\TestCase { /** @var IConfig */ private $config; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->notificationManager = $this->getMockBuilder(INotificationManager::class) @@ -88,9 +88,10 @@ public function setUp() { } /** - * @expectedException \InvalidArgumentException */ public function testPrepareInvalidApp() { + $this->expectException(\InvalidArgumentException::class); + $notification = $this->createMock(INotification::class); $notification->method('getApp')->willReturn('another'); $notification->method('getObjectType')->willReturn('local_share'); @@ -98,9 +99,10 @@ public function testPrepareInvalidApp() { } /** - * @expectedException \InvalidArgumentException */ public function testPrepareInvalidSubject() { + $this->expectException(\InvalidArgumentException::class); + $notification = $this->createMock(INotification::class); $notification->method('getApp')->willReturn('files_sharing'); $notification->method('getObjectType')->willReturn('invalid_object'); @@ -366,9 +368,10 @@ public function testPrepareWithCustomConfig($subject, $subjectParams, $displayna } /** - * @expectedException \InvalidArgumentException */ public function testPrepareShareWithGroupNotMemberAnyLonger() { + $this->expectException(\InvalidArgumentException::class); + $share = $this->createMock(IShare::class); $share->method('getShareType')->willReturn(\OCP\Share::SHARE_TYPE_GROUP); $share->method('getSharedWith')->willReturn('big group 1'); @@ -396,9 +399,10 @@ public function testPrepareShareWithGroupNotMemberAnyLonger() { } /** - * @expectedException \InvalidArgumentException */ public function testPrepareMissingShare() { + $this->expectException(\InvalidArgumentException::class); + $this->shareManager->method('getShareById') ->will($this->throwException(new ShareNotFound())); diff --git a/apps/files_sharing/tests/Panels/Admin/SettingsPanelTest.php b/apps/files_sharing/tests/Panels/Admin/SettingsPanelTest.php index 1df1fdc27d17..81c93ebd21cb 100644 --- a/apps/files_sharing/tests/Panels/Admin/SettingsPanelTest.php +++ b/apps/files_sharing/tests/Panels/Admin/SettingsPanelTest.php @@ -31,7 +31,7 @@ class SettingsPanelTest extends \Test\TestCase { /** @var SettingsPanel | \PHPUnit\Framework\MockObject\MockObject */ private $settingsPanel; - protected function setUp() { + protected function setUp(): void { $this->sharingBlacklist = $this->getMockBuilder(SharingBlacklist::class) ->disableOriginalConstructor() ->getMock(); diff --git a/apps/files_sharing/tests/Panels/Personal/PersonalPanelTest.php b/apps/files_sharing/tests/Panels/Personal/PersonalPanelTest.php index 01a510df39f5..c0516e64672d 100644 --- a/apps/files_sharing/tests/Panels/Personal/PersonalPanelTest.php +++ b/apps/files_sharing/tests/Panels/Personal/PersonalPanelTest.php @@ -36,7 +36,7 @@ class PersonalPanelTest extends \Test\TestCase { /** @var PersonalPanel $personalPanel */ private $personalPanel; - protected function setUp() { + protected function setUp(): void { $this->config = $this->getMockBuilder(IConfig::class) ->disableOriginalConstructor() ->getMock(); @@ -80,7 +80,10 @@ public function testGetPanelEmpty() { ->willReturn('no'); $templateHtml = $this->personalPanel->getPanel()->fetchPage(); - $this->assertContains('

Nothing to configure.

', $templateHtml); + $this->assertStringContainsString( + '

Nothing to configure.

', + $templateHtml + ); } public function testGetPanelNotEmpty() { @@ -100,6 +103,9 @@ public function testGetPanelNotEmpty() { ->willReturn('yes'); $templateHtml = $this->personalPanel->getPanel()->fetchPage(); - $this->assertContains('
', $templateHtml); + $this->assertStringContainsString( + '', + $templateHtml + ); } } diff --git a/apps/files_sharing/tests/Panels/Personal/SectionTest.php b/apps/files_sharing/tests/Panels/Personal/SectionTest.php index 7b5fe76d4e1a..5ec92ac7407b 100644 --- a/apps/files_sharing/tests/Panels/Personal/SectionTest.php +++ b/apps/files_sharing/tests/Panels/Personal/SectionTest.php @@ -31,7 +31,7 @@ class SectionTest extends \Test\TestCase { /** @var Section $section */ private $section; - protected function setUp() { + protected function setUp(): void { $this->l = $this->getMockBuilder(IL10N::class) ->disableOriginalConstructor() ->getMock(); diff --git a/apps/files_sharing/tests/PermissionsTest.php b/apps/files_sharing/tests/PermissionsTest.php index 6033133c6bbc..5e65522706e4 100644 --- a/apps/files_sharing/tests/PermissionsTest.php +++ b/apps/files_sharing/tests/PermissionsTest.php @@ -58,7 +58,7 @@ class PermissionsTest extends TestCase { /** @var Cache */ private $ownerCache; - protected function setUp() { + protected function setUp(): void { parent::setUp(); self::loginHelper(self::TEST_FILES_SHARING_API_USER1); @@ -109,7 +109,7 @@ protected function setUp() { $this->sharedCacheRestrictedShare = $this->sharedStorageRestrictedShare->getCache(); } - protected function tearDown() { + protected function tearDown(): void { if ($this->sharedCache) { $this->sharedCache->clear(); } diff --git a/apps/files_sharing/tests/PropagationTestCase.php b/apps/files_sharing/tests/PropagationTestCase.php index b6bf6f966096..7e5bcfc7a812 100644 --- a/apps/files_sharing/tests/PropagationTestCase.php +++ b/apps/files_sharing/tests/PropagationTestCase.php @@ -30,17 +30,17 @@ abstract class PropagationTestCase extends TestCase { protected $fileIds = []; // [$user=>[$path=>$id]] protected $fileEtags = []; // [$id=>$etag] - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { parent::setUpBeforeClass(); \OCA\Files_Sharing\Helper::registerHooks(); } - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->setUpShares(); } - protected function tearDown() { + protected function tearDown(): void { \OC_Hook::clear('OC_Filesystem', 'post_write'); \OC_Hook::clear('OC_Filesystem', 'post_delete'); \OC_Hook::clear('OC_Filesystem', 'post_rename'); diff --git a/apps/files_sharing/tests/Service/NotificationPublisherTest.php b/apps/files_sharing/tests/Service/NotificationPublisherTest.php index e6c38f9db9df..e8a63d578a00 100644 --- a/apps/files_sharing/tests/Service/NotificationPublisherTest.php +++ b/apps/files_sharing/tests/Service/NotificationPublisherTest.php @@ -51,7 +51,7 @@ class NotificationPublisherTest extends TestCase { /** @var NotificationPublisher */ private $publisher; - protected function setUp() { + protected function setUp(): void { $this->groupManager = $this->createMock('OCP\IGroupManager'); $this->userManager = $this->createMock('OCP\IUserManager'); $this->notificationManager = $this->createMock(\OCP\Notification\IManager::class); @@ -79,7 +79,7 @@ protected function setUp() { ->will($this->returnArgument(0)); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); } diff --git a/apps/files_sharing/tests/ShareTest.php b/apps/files_sharing/tests/ShareTest.php index 2b83afcc2b42..2d4eef1dcad2 100644 --- a/apps/files_sharing/tests/ShareTest.php +++ b/apps/files_sharing/tests/ShareTest.php @@ -36,7 +36,7 @@ class ShareTest extends TestCase { private static $tempStorage; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->folder = self::TEST_FOLDER_NAME; @@ -54,7 +54,7 @@ protected function setUp() { $this->view->file_put_contents($this->folder . $this->subfolder . $this->filename, $this->data); } - protected function tearDown() { + protected function tearDown(): void { self::loginHelper(self::TEST_FILES_SHARING_API_USER1); $this->view->unlink($this->filename); $this->view->deleteAll($this->folder); diff --git a/apps/files_sharing/tests/SharedMountTest.php b/apps/files_sharing/tests/SharedMountTest.php index 6ff9856cc494..72b4e9edae02 100644 --- a/apps/files_sharing/tests/SharedMountTest.php +++ b/apps/files_sharing/tests/SharedMountTest.php @@ -35,7 +35,7 @@ * @group DB */ class SharedMountTest extends TestCase { - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->folder = '/folder_share_storage_test'; @@ -49,7 +49,7 @@ protected function setUp() { $this->view->file_put_contents($this->folder . $this->filename, "file in subfolder"); } - protected function tearDown() { + protected function tearDown(): void { if ($this->view) { if ($this->view->file_exists($this->folder)) { $this->view->unlink($this->folder); diff --git a/apps/files_sharing/tests/SharedStorageTest.php b/apps/files_sharing/tests/SharedStorageTest.php index 513fa61957d4..754e0c5eeada 100644 --- a/apps/files_sharing/tests/SharedStorageTest.php +++ b/apps/files_sharing/tests/SharedStorageTest.php @@ -39,7 +39,7 @@ * @group DB */ class SharedStorageTest extends TestCase { - protected function setUp() { + protected function setUp(): void { parent::setUp(); \OCA\Files_Trashbin\Trashbin::registerHooks(); $this->folder = '/folder_share_storage_test'; @@ -53,7 +53,7 @@ protected function setUp() { $this->view->file_put_contents($this->folder . $this->filename, "file in subfolder"); } - protected function tearDown() { + protected function tearDown(): void { if ($this->view) { if ($this->view->file_exists($this->folder)) { $this->view->unlink($this->folder); @@ -137,7 +137,7 @@ public function testRenamePartFile() { // create part file $result = $user2View->file_put_contents($this->folder . '/foo.txt.part', 'some test data'); - $this->assertInternalType('int', $result); + $this->assertIsInt($result); // rename part file to real file $result = $user2View->rename($this->folder . '/foo.txt.part', $this->folder . '/foo.txt'); diff --git a/apps/files_sharing/tests/SharingBlacklistTest.php b/apps/files_sharing/tests/SharingBlacklistTest.php index d22b950ccf6f..dc0515d04a0f 100644 --- a/apps/files_sharing/tests/SharingBlacklistTest.php +++ b/apps/files_sharing/tests/SharingBlacklistTest.php @@ -32,7 +32,7 @@ class SharingBlacklistTest extends \Test\TestCase { /** @var SharingBlacklist | \PHPUnit\Framework\MockObject\MockObject */ private $sharingBlacklist; - public function setUp() { + public function setUp(): void { $this->config = $this->getMockBuilder(IConfig::class) ->disableOriginalConstructor() ->getMock(); diff --git a/apps/files_sharing/tests/TestCase.php b/apps/files_sharing/tests/TestCase.php index 6632407cf123..b93c67703d48 100644 --- a/apps/files_sharing/tests/TestCase.php +++ b/apps/files_sharing/tests/TestCase.php @@ -71,7 +71,7 @@ abstract class TestCase extends \Test\TestCase { private static $alreadyRegistered = false; - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { parent::setUpBeforeClass(); if (!self::$alreadyRegistered) { @@ -89,7 +89,7 @@ public static function setUpBeforeClass() { \OC::registerShareHooks(); } - protected function setUp() { + protected function setUp(): void { parent::setUp(); // create users @@ -124,14 +124,14 @@ protected function setUp() { $this->rootFolder = \OC::$server->getRootFolder(); } - protected function tearDown() { + protected function tearDown(): void { $query = \OCP\DB::prepare('DELETE FROM `*PREFIX*share`'); $query->execute(); parent::tearDown(); } - public static function tearDownAfterClass() { + public static function tearDownAfterClass(): void { // delete group $group = \OC::$server->getGroupManager()->get(self::TEST_FILES_SHARING_API_GROUP1); if ($group !== null) { diff --git a/apps/files_sharing/tests/UnshareChildrenTest.php b/apps/files_sharing/tests/UnshareChildrenTest.php index 4bb6cfef94c0..afe6779a1dcf 100644 --- a/apps/files_sharing/tests/UnshareChildrenTest.php +++ b/apps/files_sharing/tests/UnshareChildrenTest.php @@ -40,7 +40,7 @@ class UnshareChildrenTest extends TestCase { private static $tempStorage; - protected function setUp() { + protected function setUp(): void { parent::setUp(); \OCP\Util::connectHook('OC_Filesystem', 'post_delete', '\OCA\Files_Sharing\Hooks', 'unshareChildren'); @@ -59,7 +59,7 @@ protected function setUp() { $this->view->file_put_contents($this->folder . $this->subfolder . $this->filename, $this->data); } - protected function tearDown() { + protected function tearDown(): void { if ($this->view) { $this->view->deleteAll($this->folder); } diff --git a/apps/files_sharing/tests/UpdaterTest.php b/apps/files_sharing/tests/UpdaterTest.php index 12eb8af0369c..1091e17c21ba 100644 --- a/apps/files_sharing/tests/UpdaterTest.php +++ b/apps/files_sharing/tests/UpdaterTest.php @@ -37,12 +37,12 @@ class UpdaterTest extends TestCase { const TEST_FOLDER_NAME = '/folder_share_updater_test'; - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { parent::setUpBeforeClass(); \OCA\Files_Sharing\Helper::registerHooks(); } - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->folder = self::TEST_FOLDER_NAME; @@ -55,7 +55,7 @@ protected function setUp() { $this->view->file_put_contents($this->folder . '/' . $this->filename, $this->data); } - protected function tearDown() { + protected function tearDown(): void { if ($this->view) { $this->view->unlink($this->filename); $this->view->deleteAll($this->folder); @@ -178,10 +178,10 @@ public function testShareFile($shareFolder) { $afterShareDir = \OC\Files\Filesystem::getFileInfo($shareFolder); $etagAfterShareDir = $afterShareDir->getEtag(); - $this->assertInternalType('string', $etagBeforeShareRoot); - $this->assertInternalType('string', $etagBeforeShareDir); - $this->assertInternalType('string', $etagAfterShareRoot); - $this->assertInternalType('string', $etagAfterShareDir); + $this->assertIsString($etagBeforeShareRoot); + $this->assertIsString($etagBeforeShareDir); + $this->assertIsString($etagAfterShareRoot); + $this->assertIsString($etagAfterShareDir); $this->assertNotSame($etagBeforeShareRoot, $etagAfterShareRoot); $this->assertNotSame($etagBeforeShareDir, $etagAfterShareDir); diff --git a/apps/files_sharing/tests/WatcherTest.php b/apps/files_sharing/tests/WatcherTest.php index e700cabf04e0..6e745d529db4 100644 --- a/apps/files_sharing/tests/WatcherTest.php +++ b/apps/files_sharing/tests/WatcherTest.php @@ -50,7 +50,7 @@ class WatcherTest extends TestCase { /** @var \OCP\Share\IShare */ private $_share; - protected function setUp() { + protected function setUp(): void { parent::setUp(); self::loginHelper(self::TEST_FILES_SHARING_API_USER1); @@ -82,7 +82,7 @@ protected function setUp() { $this->sharedCache = $this->sharedStorage->getCache(); } - protected function tearDown() { + protected function tearDown(): void { if ($this->sharedCache) { $this->sharedCache->clear(); } diff --git a/apps/files_trashbin/tests/Command/CleanUpTest.php b/apps/files_trashbin/tests/Command/CleanUpTest.php index a270e5300d73..6ff10481d5d7 100644 --- a/apps/files_trashbin/tests/Command/CleanUpTest.php +++ b/apps/files_trashbin/tests/Command/CleanUpTest.php @@ -55,7 +55,7 @@ class CleanUpTest extends TestCase { /** @var string */ protected $user0 = 'user0'; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->rootFolder = $this->getMockBuilder('OCP\Files\IRootFolder') ->disableOriginalConstructor()->getMock(); diff --git a/apps/files_trashbin/tests/Command/ExpireTrashTest.php b/apps/files_trashbin/tests/Command/ExpireTrashTest.php index b6f781248823..49890dc7ad8b 100644 --- a/apps/files_trashbin/tests/Command/ExpireTrashTest.php +++ b/apps/files_trashbin/tests/Command/ExpireTrashTest.php @@ -43,7 +43,7 @@ class ExpireTrashTest extends TestCase { private $expiration; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->userManager = $this->createMock(IUserManager::class); @@ -57,6 +57,6 @@ public function testExpireNoMaxRetention() { ->willReturn(false); $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains('Auto expiration is configured', $output); + $this->assertStringContainsString('Auto expiration is configured', $output); } } diff --git a/apps/files_trashbin/tests/QuotaTest.php b/apps/files_trashbin/tests/QuotaTest.php index 29a225fabfd5..571e313d581a 100644 --- a/apps/files_trashbin/tests/QuotaTest.php +++ b/apps/files_trashbin/tests/QuotaTest.php @@ -31,7 +31,7 @@ class QuotaTest extends \Test\TestCase { /** @var IConfig | \PHPUnit\Framework\MockObject\MockObject */ protected $config; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userManager = $this->getMockBuilder(IUserManager::class) diff --git a/apps/files_trashbin/tests/StorageTest.php b/apps/files_trashbin/tests/StorageTest.php index 8f839e9eacd1..ea8faf331e4e 100644 --- a/apps/files_trashbin/tests/StorageTest.php +++ b/apps/files_trashbin/tests/StorageTest.php @@ -61,7 +61,7 @@ class StorageTest extends TestCase { */ private $userView; - protected function setUp() { + protected function setUp(): void { parent::setUp(); \OC_Hook::clear(); @@ -87,7 +87,7 @@ protected function setUp() { $this->userView->file_put_contents('folder/inside.txt', 'bar'); } - protected function tearDown() { + protected function tearDown(): void { \OC\Files\Filesystem::getLoader()->removeStorageWrapper('oc_trashbin'); $this->logout(); \OC_Hook::clear(); diff --git a/apps/files_trashbin/tests/TrashbinTest.php b/apps/files_trashbin/tests/TrashbinTest.php index 0455b7ea98ab..b997115c5228 100644 --- a/apps/files_trashbin/tests/TrashbinTest.php +++ b/apps/files_trashbin/tests/TrashbinTest.php @@ -69,7 +69,7 @@ class TrashbinTest extends TestCase { */ private $rootView; - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { parent::setUpBeforeClass(); $appManager = \OC::$server->getAppManager(); @@ -97,7 +97,7 @@ public static function setUpBeforeClass() { self::loginHelper(self::TEST_TRASHBIN_USER1, true); } - public static function tearDownAfterClass() { + public static function tearDownAfterClass(): void { // cleanup test user $user = \OC::$server->getUserManager()->get(self::TEST_TRASHBIN_USER1); if ($user !== null) { @@ -121,7 +121,7 @@ public static function tearDownAfterClass() { parent::tearDownAfterClass(); } - protected function setUp() { + protected function setUp(): void { parent::setUp(); \OC::$server->getAppManager()->enableApp('files_trashbin'); @@ -144,7 +144,7 @@ protected function setUp() { self::loginHelper(self::TEST_TRASHBIN_USER1); } - protected function tearDown() { + protected function tearDown(): void { $this->restoreService('AllConfig'); // disable trashbin to be able to properly clean up \OC::$server->getAppManager()->disableApp('files_trashbin'); diff --git a/apps/files_versions/tests/Command/CleanupTest.php b/apps/files_versions/tests/Command/CleanupTest.php index 6ffb300de449..6f96ce8782b2 100644 --- a/apps/files_versions/tests/Command/CleanupTest.php +++ b/apps/files_versions/tests/Command/CleanupTest.php @@ -45,7 +45,7 @@ class CleanupTest extends TestCase { /** @var \PHPUnit\Framework\MockObject\MockObject | IRootFolder */ protected $rootFolder; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->rootFolder = $this->getMockBuilder('OCP\Files\IRootFolder') diff --git a/apps/files_versions/tests/Command/ExpireVersionsTest.php b/apps/files_versions/tests/Command/ExpireVersionsTest.php index e9e3634b77a3..6a4996024338 100644 --- a/apps/files_versions/tests/Command/ExpireVersionsTest.php +++ b/apps/files_versions/tests/Command/ExpireVersionsTest.php @@ -43,7 +43,7 @@ class ExpireVersionsTest extends TestCase { private $expiration; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->userManager = $this->createMock(IUserManager::class); @@ -57,6 +57,6 @@ public function testExpireNoMaxRetention() { ->willReturn(false); $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains('Auto expiration is configured', $output); + $this->assertStringContainsString('Auto expiration is configured', $output); } } diff --git a/apps/files_versions/tests/VersioningTest.php b/apps/files_versions/tests/VersioningTest.php index 2cf21942eb46..89f016a59202 100644 --- a/apps/files_versions/tests/VersioningTest.php +++ b/apps/files_versions/tests/VersioningTest.php @@ -61,14 +61,14 @@ class VersioningTest extends TestCase { */ private $rootView; - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { parent::setUpBeforeClass(); $application = new \OCA\Files_Sharing\AppInfo\Application(); $application->registerMountProviders(); } - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = \OC::$server->getConfig(); @@ -108,7 +108,7 @@ protected function setUp() { } } - protected function tearDown() { + protected function tearDown(): void { $this->restoreService('AllConfig'); if ($this->rootView) { @@ -619,9 +619,10 @@ public function testExpireNonexistingFile() { } /** - * @expectedException \OC\User\NoUserException */ public function testExpireNonexistingUser() { + $this->expectException(\OC\User\NoUserException::class); + $this->logout(); // needed to have a FS setup (the background job does this) \OC_Util::setupFS($this->user1); diff --git a/apps/provisioning_api/tests/AppsTest.php b/apps/provisioning_api/tests/AppsTest.php index 00eda3f95c65..1a01a7303cc0 100644 --- a/apps/provisioning_api/tests/AppsTest.php +++ b/apps/provisioning_api/tests/AppsTest.php @@ -45,7 +45,7 @@ class AppsTest extends TestCase { /** @var IUserSession */ private $userSession; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->appManager = \OC::$server->getAppManager(); diff --git a/apps/provisioning_api/tests/GroupsTest.php b/apps/provisioning_api/tests/GroupsTest.php index 4d9bfeea2008..b007f5052899 100644 --- a/apps/provisioning_api/tests/GroupsTest.php +++ b/apps/provisioning_api/tests/GroupsTest.php @@ -45,7 +45,7 @@ class GroupsTest extends \Test\TestCase { /** @var Groups */ protected $api; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->subAdminManager = $this->getMockBuilder('OC\SubAdmin') diff --git a/apps/provisioning_api/tests/TestCase.php b/apps/provisioning_api/tests/TestCase.php index 4a60bde4aef1..4d1ade402b1a 100644 --- a/apps/provisioning_api/tests/TestCase.php +++ b/apps/provisioning_api/tests/TestCase.php @@ -39,7 +39,7 @@ abstract class TestCase extends \Test\TestCase { /** @var IGroupManager */ protected $groupManager; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userManager = \OC::$server->getUserManager(); @@ -62,7 +62,7 @@ protected function generateUsers($num = 1) { return \count($users) == 1 ? \reset($users) : $users; } - protected function tearDown() { + protected function tearDown(): void { foreach ($this->users as $user) { $user->delete(); } diff --git a/apps/provisioning_api/tests/UsersTest.php b/apps/provisioning_api/tests/UsersTest.php index 0c1b7503faf3..d4eb95e4da5d 100644 --- a/apps/provisioning_api/tests/UsersTest.php +++ b/apps/provisioning_api/tests/UsersTest.php @@ -57,13 +57,13 @@ class UsersTest extends OriginalTest { /** @var \OC\Authentication\TwoFactorAuth\Manager | PHPUnit\Framework\MockObject\MockObject */ private $twoFactorAuthManager; - protected function tearDown() { + protected function tearDown(): void { $_GET = null; $_POST = null; parent::tearDown(); } - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userManager = $this->createMock(IUserManager::class); diff --git a/apps/systemtags/tests/unit/activity/ExtensionTest.php b/apps/systemtags/tests/unit/activity/ExtensionTest.php index 62b1d30fd663..e9f2dceb3467 100644 --- a/apps/systemtags/tests/unit/activity/ExtensionTest.php +++ b/apps/systemtags/tests/unit/activity/ExtensionTest.php @@ -42,7 +42,7 @@ class ExtensionTest extends TestCase { /** @var Extension */ private $extension; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->languageFactory = $this->createMock(IFactory::class); diff --git a/apps/systemtags/tests/unit/activity/ListenerTest.php b/apps/systemtags/tests/unit/activity/ListenerTest.php index 1ecc2df62897..c6fe0901927b 100644 --- a/apps/systemtags/tests/unit/activity/ListenerTest.php +++ b/apps/systemtags/tests/unit/activity/ListenerTest.php @@ -83,7 +83,7 @@ class ActivityListenerTest extends \Test\TestCase { */ private $activityManager; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->groupManager = $this->createMock(IGroupManager::class); diff --git a/apps/updatenotification/tests/Controller/AdminControllerTest.php b/apps/updatenotification/tests/Controller/AdminControllerTest.php index 7272044ae392..36d6d7de6a78 100644 --- a/apps/updatenotification/tests/Controller/AdminControllerTest.php +++ b/apps/updatenotification/tests/Controller/AdminControllerTest.php @@ -58,7 +58,7 @@ class AdminControllerTest extends TestCase { /** @var IDateTimeFormatter */ private $dateTimeFormatter; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->createMock('\\OCP\\IRequest'); @@ -202,7 +202,7 @@ public function testCreateCredentials() { } public function testGetPriority() { - $this->assertInternalType('int', $this->adminController->getPriority()); + $this->assertIsInt($this->adminController->getPriority()); } public function testGetSectionID() { diff --git a/apps/updatenotification/tests/Notification/BackgroundJobTest.php b/apps/updatenotification/tests/Notification/BackgroundJobTest.php index f96df597a20d..8e5676f8ecd9 100644 --- a/apps/updatenotification/tests/Notification/BackgroundJobTest.php +++ b/apps/updatenotification/tests/Notification/BackgroundJobTest.php @@ -47,7 +47,7 @@ class BackgroundJobTest extends TestCase { /** @var IURLGenerator|\PHPUnit\Framework\MockObject\MockObject */ protected $urlGenerator; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->createMock('OCP\IConfig'); diff --git a/apps/updatenotification/tests/Notification/NotifierTest.php b/apps/updatenotification/tests/Notification/NotifierTest.php index 15332a0f3755..288dfd19cbe1 100644 --- a/apps/updatenotification/tests/Notification/NotifierTest.php +++ b/apps/updatenotification/tests/Notification/NotifierTest.php @@ -34,7 +34,7 @@ class NotifierTest extends TestCase { /** @var IFactory|\PHPUnit\Framework\MockObject\MockObject */ protected $l10nFactory; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->notificationManager = $this->createMock('OCP\Notification\IManager'); diff --git a/apps/updatenotification/tests/ResetTokenBackgroundJobTest.php b/apps/updatenotification/tests/ResetTokenBackgroundJobTest.php index a3059047b193..efe81a653b25 100644 --- a/apps/updatenotification/tests/ResetTokenBackgroundJobTest.php +++ b/apps/updatenotification/tests/ResetTokenBackgroundJobTest.php @@ -35,7 +35,7 @@ class ResetTokenBackgroundJobTest extends TestCase { /** @var ITimeFactory */ private $timeFactory; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->createMock('\\OCP\\IConfig'); $this->timeFactory = $this->createMock('\\OCP\\AppFramework\\Utility\\ITimeFactory'); diff --git a/apps/updatenotification/tests/UpdateCheckerTest.php b/apps/updatenotification/tests/UpdateCheckerTest.php index d80160c3b0c8..1c8eb68ea003 100644 --- a/apps/updatenotification/tests/UpdateCheckerTest.php +++ b/apps/updatenotification/tests/UpdateCheckerTest.php @@ -32,7 +32,7 @@ class UpdateCheckerTest extends TestCase { /** @var UpdateChecker */ private $updateChecker; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->updater = $this->getMockBuilder('\OC\Updater\VersionCheck') diff --git a/composer.json b/composer.json index 58deb71da0ee..fe05e2fb317e 100644 --- a/composer.json +++ b/composer.json @@ -7,7 +7,7 @@ "optimize-autoloader": true, "classmap-authoritative": false, "platform": { - "php": "7.1" + "php": "7.2" } }, "autoload" : { @@ -26,11 +26,11 @@ "bamarni/composer-bin-plugin": "^1.2", "jakub-onderka/php-console-highlighter": "^0.4", "mikey179/vfsstream": "^1.6", - "phpunit/phpunit": "^7.5", + "phpunit/phpunit": "^8.4", "roave/security-advisories": "dev-master" }, "require": { - "php": ">=7.1", + "php": ">=7.2", "doctrine/dbal": "^2.8", "phpseclib/phpseclib": "^2.0", "jeremeamia/superclosure": "^2.4", diff --git a/composer.lock b/composer.lock index a8d2cb35740c..6235fb67a65e 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "3e027015240ee48c59e781bd63f1d61e", + "content-hash": "0ea0120a0fa045d40fddd9dfbcb9c953", "packages": [ { "name": "bantu/ini-get-wrapper", @@ -285,16 +285,16 @@ }, { "name": "doctrine/cache", - "version": "1.9.1", + "version": "1.10.0", "source": { "type": "git", "url": "https://github.com/doctrine/cache.git", - "reference": "89a5c76c39c292f7798f964ab3c836c3f8192a55" + "reference": "382e7f4db9a12dc6c19431743a2b096041bcdd62" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/cache/zipball/89a5c76c39c292f7798f964ab3c836c3f8192a55", - "reference": "89a5c76c39c292f7798f964ab3c836c3f8192a55", + "url": "https://api.github.com/repos/doctrine/cache/zipball/382e7f4db9a12dc6c19431743a2b096041bcdd62", + "reference": "382e7f4db9a12dc6c19431743a2b096041bcdd62", "shasum": "" }, "require": { @@ -361,38 +361,36 @@ "memcached", "php", "redis", - "riak", "xcache" ], - "time": "2019-11-15T14:31:57+00:00" + "time": "2019-11-29T15:36:20+00:00" }, { "name": "doctrine/dbal", - "version": "v2.9.3", + "version": "v2.10.0", "source": { "type": "git", "url": "https://github.com/doctrine/dbal.git", - "reference": "7345cd59edfa2036eb0fa4264b77ae2576842035" + "reference": "0c9a646775ef549eb0a213a4f9bd4381d9b4d934" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/7345cd59edfa2036eb0fa4264b77ae2576842035", - "reference": "7345cd59edfa2036eb0fa4264b77ae2576842035", + "url": "https://api.github.com/repos/doctrine/dbal/zipball/0c9a646775ef549eb0a213a4f9bd4381d9b4d934", + "reference": "0c9a646775ef549eb0a213a4f9bd4381d9b4d934", "shasum": "" }, "require": { "doctrine/cache": "^1.0", "doctrine/event-manager": "^1.0", "ext-pdo": "*", - "php": "^7.1" + "php": "^7.2" }, "require-dev": { - "doctrine/coding-standard": "^5.0", - "jetbrains/phpstorm-stubs": "^2018.1.2", - "phpstan/phpstan": "^0.10.1", - "phpunit/phpunit": "^7.4", - "symfony/console": "^2.0.5|^3.0|^4.0", - "symfony/phpunit-bridge": "^3.4.5|^4.0.5" + "doctrine/coding-standard": "^6.0", + "jetbrains/phpstorm-stubs": "^2019.1", + "phpstan/phpstan": "^0.11.3", + "phpunit/phpunit": "^8.4.1", + "symfony/console": "^2.0.5|^3.0|^4.0|^5.0" }, "suggest": { "symfony/console": "For helpful console commands such as SQL execution and import of files." @@ -403,7 +401,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.9.x-dev", + "dev-master": "2.10.x-dev", "dev-develop": "3.0.x-dev" } }, @@ -439,14 +437,25 @@ "keywords": [ "abstraction", "database", + "db2", "dbal", + "mariadb", + "mssql", "mysql", - "persistence", + "oci8", + "oracle", + "pdo", "pgsql", - "php", - "queryobject" - ], - "time": "2019-11-02T22:19:34+00:00" + "postgresql", + "queryobject", + "sasql", + "sql", + "sqlanywhere", + "sqlite", + "sqlserver", + "sqlsrv" + ], + "time": "2019-11-03T16:50:43+00:00" }, { "name": "doctrine/event-manager", @@ -526,28 +535,30 @@ }, { "name": "doctrine/lexer", - "version": "1.0.2", + "version": "1.2.0", "source": { "type": "git", "url": "https://github.com/doctrine/lexer.git", - "reference": "1febd6c3ef84253d7c815bed85fc622ad207a9f8" + "reference": "5242d66dbeb21a30dd8a3e66bf7a73b66e05e1f6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/1febd6c3ef84253d7c815bed85fc622ad207a9f8", - "reference": "1febd6c3ef84253d7c815bed85fc622ad207a9f8", + "url": "https://api.github.com/repos/doctrine/lexer/zipball/5242d66dbeb21a30dd8a3e66bf7a73b66e05e1f6", + "reference": "5242d66dbeb21a30dd8a3e66bf7a73b66e05e1f6", "shasum": "" }, "require": { - "php": ">=5.3.2" + "php": "^7.2" }, "require-dev": { - "phpunit/phpunit": "^4.5" + "doctrine/coding-standard": "^6.0", + "phpstan/phpstan": "^0.11.8", + "phpunit/phpunit": "^8.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.2.x-dev" } }, "autoload": { @@ -560,14 +571,14 @@ "MIT" ], "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, { "name": "Guilherme Blanco", "email": "guilhermeblanco@gmail.com" }, + { + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, { "name": "Johannes Schmitt", "email": "schmittjoh@gmail.com" @@ -582,7 +593,7 @@ "parser", "php" ], - "time": "2019-06-08T11:03:04+00:00" + "time": "2019-10-30T14:39:59+00:00" }, { "name": "egulias/email-validator", @@ -2334,32 +2345,32 @@ }, { "name": "symfony/debug", - "version": "v3.4.35", + "version": "v4.4.0", "source": { "type": "git", "url": "https://github.com/symfony/debug.git", - "reference": "f72e33fdb1170b326e72c3157f0cd456351dd086" + "reference": "b24b791f817116b29e52a63e8544884cf9a40757" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/f72e33fdb1170b326e72c3157f0cd456351dd086", - "reference": "f72e33fdb1170b326e72c3157f0cd456351dd086", + "url": "https://api.github.com/repos/symfony/debug/zipball/b24b791f817116b29e52a63e8544884cf9a40757", + "reference": "b24b791f817116b29e52a63e8544884cf9a40757", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8", + "php": "^7.1.3", "psr/log": "~1.0" }, "conflict": { - "symfony/http-kernel": ">=2.3,<2.3.24|~2.4.0|>=2.5,<2.5.9|>=2.6,<2.6.2" + "symfony/http-kernel": "<3.4" }, "require-dev": { - "symfony/http-kernel": "~2.8|~3.0|~4.0" + "symfony/http-kernel": "^3.4|^4.0|^5.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.4-dev" + "dev-master": "4.4-dev" } }, "autoload": { @@ -2386,7 +2397,7 @@ ], "description": "Symfony Debug Component", "homepage": "https://symfony.com", - "time": "2019-10-24T15:33:53+00:00" + "time": "2019-11-10T17:54:30+00:00" }, { "name": "symfony/event-dispatcher", @@ -2453,7 +2464,7 @@ }, { "name": "symfony/polyfill-iconv", - "version": "v1.13.0", + "version": "v1.13.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-iconv.git", @@ -2512,7 +2523,7 @@ }, { "name": "symfony/polyfill-intl-idn", - "version": "v1.13.0", + "version": "v1.13.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-idn.git", @@ -2574,7 +2585,7 @@ }, { "name": "symfony/polyfill-mbstring", - "version": "v1.13.0", + "version": "v1.13.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", @@ -2633,7 +2644,7 @@ }, { "name": "symfony/polyfill-php56", - "version": "v1.13.0", + "version": "v1.13.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php56.git", @@ -2689,7 +2700,7 @@ }, { "name": "symfony/polyfill-php72", - "version": "v1.13.0", + "version": "v1.13.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php72.git", @@ -2744,7 +2755,7 @@ }, { "name": "symfony/polyfill-util", - "version": "v1.13.0", + "version": "v1.13.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-util.git", @@ -3894,40 +3905,40 @@ }, { "name": "phpunit/php-code-coverage", - "version": "6.1.4", + "version": "7.0.10", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d" + "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f1884187926fbb755a9aaf0b3836ad3165b478bf", + "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf", "shasum": "" }, "require": { "ext-dom": "*", "ext-xmlwriter": "*", - "php": "^7.1", - "phpunit/php-file-iterator": "^2.0", + "php": "^7.2", + "phpunit/php-file-iterator": "^2.0.2", "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.0", + "phpunit/php-token-stream": "^3.1.1", "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^3.1 || ^4.0", + "sebastian/environment": "^4.2.2", "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1" + "theseer/tokenizer": "^1.1.3" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^8.2.2" }, "suggest": { - "ext-xdebug": "^2.6.0" + "ext-xdebug": "^2.7.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "6.1-dev" + "dev-master": "7.0-dev" } }, "autoload": { @@ -3953,7 +3964,7 @@ "testing", "xunit" ], - "time": "2018-10-31T16:06:48+00:00" + "time": "2019-11-20T13:55:58+00:00" }, { "name": "phpunit/php-file-iterator", @@ -4146,53 +4157,52 @@ }, { "name": "phpunit/phpunit", - "version": "7.5.17", + "version": "8.4.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "4c92a15296e58191a4cd74cff3b34fc8e374174a" + "reference": "67f9e35bffc0dd52d55d565ddbe4230454fd6a4e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/4c92a15296e58191a4cd74cff3b34fc8e374174a", - "reference": "4c92a15296e58191a4cd74cff3b34fc8e374174a", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/67f9e35bffc0dd52d55d565ddbe4230454fd6a4e", + "reference": "67f9e35bffc0dd52d55d565ddbe4230454fd6a4e", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.1", + "doctrine/instantiator": "^1.2.0", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", - "myclabs/deep-copy": "^1.7", - "phar-io/manifest": "^1.0.2", - "phar-io/version": "^2.0", - "php": "^7.1", - "phpspec/prophecy": "^1.7", - "phpunit/php-code-coverage": "^6.0.7", - "phpunit/php-file-iterator": "^2.0.1", + "ext-xmlwriter": "*", + "myclabs/deep-copy": "^1.9.1", + "phar-io/manifest": "^1.0.3", + "phar-io/version": "^2.0.1", + "php": "^7.2", + "phpspec/prophecy": "^1.8.1", + "phpunit/php-code-coverage": "^7.0.7", + "phpunit/php-file-iterator": "^2.0.2", "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1", - "sebastian/comparator": "^3.0", - "sebastian/diff": "^3.0", - "sebastian/environment": "^4.0", - "sebastian/exporter": "^3.1", - "sebastian/global-state": "^2.0", + "phpunit/php-timer": "^2.1.2", + "sebastian/comparator": "^3.0.2", + "sebastian/diff": "^3.0.2", + "sebastian/environment": "^4.2.2", + "sebastian/exporter": "^3.1.1", + "sebastian/global-state": "^3.0.0", "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0", + "sebastian/resource-operations": "^2.0.1", + "sebastian/type": "^1.1.3", "sebastian/version": "^2.0.1" }, - "conflict": { - "phpunit/phpunit-mock-objects": "*" - }, "require-dev": { "ext-pdo": "*" }, "suggest": { "ext-soap": "*", "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0" + "phpunit/php-invoker": "^2.0.0" }, "bin": [ "phpunit" @@ -4200,7 +4210,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "7.5-dev" + "dev-master": "8.4-dev" } }, "autoload": { @@ -4226,7 +4236,7 @@ "testing", "xunit" ], - "time": "2019-10-28T10:37:36+00:00" + "time": "2019-11-06T09:42:23+00:00" }, { "name": "roave/security-advisories", @@ -4234,12 +4244,12 @@ "source": { "type": "git", "url": "https://github.com/Roave/SecurityAdvisories.git", - "reference": "7b05f1705362f8a8a4b535ec5c0f174eaf4d09ec" + "reference": "9986511fcd47e8b8ec491884cc18beee1773548a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/7b05f1705362f8a8a4b535ec5c0f174eaf4d09ec", - "reference": "7b05f1705362f8a8a4b535ec5c0f174eaf4d09ec", + "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/9986511fcd47e8b8ec491884cc18beee1773548a", + "reference": "9986511fcd47e8b8ec491884cc18beee1773548a", "shasum": "" }, "conflict": { @@ -4342,7 +4352,7 @@ "silverstripe/userforms": "<3", "simple-updates/phpwhois": "<=1", "simplesamlphp/saml2": "<1.10.6|>=2,<2.3.8|>=3,<3.1.4", - "simplesamlphp/simplesamlphp": "<1.18", + "simplesamlphp/simplesamlphp": "<1.17.8", "simplesamlphp/simplesamlphp-module-infocard": "<1.0.1", "slim/slim": "<2.6", "smarty/smarty": "<3.1.33", @@ -4444,7 +4454,7 @@ } ], "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it", - "time": "2019-11-27T20:26:33+00:00" + "time": "2019-11-29T17:22:08+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -4733,23 +4743,26 @@ }, { "name": "sebastian/global-state", - "version": "2.0.0", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4" + "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", + "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", "shasum": "" }, "require": { - "php": "^7.0" + "php": "^7.2", + "sebastian/object-reflector": "^1.1.1", + "sebastian/recursion-context": "^3.0" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "ext-dom": "*", + "phpunit/phpunit": "^8.0" }, "suggest": { "ext-uopz": "*" @@ -4757,7 +4770,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -4780,7 +4793,7 @@ "keywords": [ "global state" ], - "time": "2017-04-27T15:39:26+00:00" + "time": "2019-02-01T05:30:01+00:00" }, { "name": "sebastian/object-enumerator", @@ -4969,6 +4982,52 @@ "homepage": "https://www.github.com/sebastianbergmann/resource-operations", "time": "2018-10-04T04:07:39+00:00" }, + { + "name": "sebastian/type", + "version": "1.1.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/3aaaa15fa71d27650d62a948be022fe3b48541a3", + "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3", + "shasum": "" + }, + "require": { + "php": "^7.2" + }, + "require-dev": { + "phpunit/phpunit": "^8.2" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the types of the PHP type system", + "homepage": "https://github.com/sebastianbergmann/type", + "time": "2019-07-02T08:10:15+00:00" + }, { "name": "sebastian/version", "version": "2.0.1", @@ -5014,7 +5073,7 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.13.0", + "version": "v1.13.1", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", @@ -5167,11 +5226,11 @@ "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": ">=7.1", + "php": ">=7.2", "ext-json": "*" }, "platform-dev": [], "platform-overrides": { - "php": "7.1" + "php": "7.2" } } diff --git a/console.php b/console.php index 92365fa227a6..3d6a3b55a052 100644 --- a/console.php +++ b/console.php @@ -33,10 +33,10 @@ \define('OC_CONSOLE', 1); -// Show warning if a PHP version below 7.1.0 is used, this has to happen here -// because base.php will already use 7.1 syntax. -if (\version_compare(PHP_VERSION, '7.1.0') === -1) { - echo 'This version of ownCloud requires at least PHP 7.1.0'.PHP_EOL; +// Show warning if a PHP version below 7.2.0 is used, this has to happen here +// because base.php will already use 7.2 syntax. +if (\version_compare(PHP_VERSION, '7.2.0') === -1) { + echo 'This version of ownCloud requires at least PHP 7.2.0'.PHP_EOL; echo 'You are currently running PHP ' . PHP_VERSION . '. Please update your PHP version.'.PHP_EOL; exit(1); } diff --git a/index.php b/index.php index 0e36dddc8ed6..582ec928fc8e 100644 --- a/index.php +++ b/index.php @@ -27,10 +27,10 @@ * */ -// Show warning if a PHP version below 7.1.0 is used, this has to happen here -// because base.php will already use 7.1 syntax. -if (\version_compare(PHP_VERSION, '7.1.0') === -1) { - echo 'This version of ownCloud requires at least PHP 7.1.0
'; +// Show warning if a PHP version below 7.2.0 is used, this has to happen here +// because base.php will already use 7.2 syntax. +if (\version_compare(PHP_VERSION, '7.2.0') === -1) { + echo 'This version of ownCloud requires at least PHP 7.2.0
'; echo 'You are currently running PHP ' . PHP_VERSION . '. Please update your PHP version.'; return; } diff --git a/tests/Core/Command/Apps/AppsDisableTest.php b/tests/Core/Command/Apps/AppsDisableTest.php index 6c0d2f3e2d01..74f63d3ad320 100644 --- a/tests/Core/Command/Apps/AppsDisableTest.php +++ b/tests/Core/Command/Apps/AppsDisableTest.php @@ -35,7 +35,7 @@ class AppsDisableTest extends TestCase { /** @var CommandTester */ private $commandTester; - public function setUp() { + public function setUp(): void { parent::setUp(); $command = new Disable(\OC::$server->getAppManager()); @@ -53,7 +53,7 @@ public function testCommandInput($appId, $expectedOutput) { $input = ['app-id' => $appId]; $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function providesAppIds() { diff --git a/tests/Core/Command/Apps/AppsEnableTest.php b/tests/Core/Command/Apps/AppsEnableTest.php index 59bfdc700f2b..ca24d07d90cb 100644 --- a/tests/Core/Command/Apps/AppsEnableTest.php +++ b/tests/Core/Command/Apps/AppsEnableTest.php @@ -35,7 +35,7 @@ class AppsEnableTest extends TestCase { /** @var CommandTester */ private $commandTester; - public function setUp() { + public function setUp(): void { parent::setUp(); $command = new Enable(\OC::$server->getAppManager()); @@ -55,7 +55,7 @@ public function testCommandInput($appId, $expectedOutput, $group = null) { } $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function providesAppIds() { diff --git a/tests/Core/Command/Apps/AppsGetPathTest.php b/tests/Core/Command/Apps/AppsGetPathTest.php index fe2020afe412..49158d62f8b1 100644 --- a/tests/Core/Command/Apps/AppsGetPathTest.php +++ b/tests/Core/Command/Apps/AppsGetPathTest.php @@ -35,7 +35,7 @@ class AppsGetPathTest extends TestCase { /** @var CommandTester */ private $commandTester; - public function setUp() { + public function setUp(): void { parent::setUp(); $command = new GetPath(); @@ -50,7 +50,7 @@ public function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function providesAppIds() { diff --git a/tests/Core/Command/Apps/AppsListTest.php b/tests/Core/Command/Apps/AppsListTest.php index 63d3a6e0e2d8..2d7b364088f2 100644 --- a/tests/Core/Command/Apps/AppsListTest.php +++ b/tests/Core/Command/Apps/AppsListTest.php @@ -35,7 +35,7 @@ class AppsListTest extends TestCase { /** @var CommandTester */ private $commandTester; - public function setUp() { + public function setUp(): void { parent::setUp(); $command = new ListApps(\OC::$server->getAppManager()); @@ -52,7 +52,7 @@ public function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function providesAppIds() { diff --git a/tests/Core/Command/Apps/CheckCodeTest.php b/tests/Core/Command/Apps/CheckCodeTest.php index 730a1a41611e..90edb4322e60 100644 --- a/tests/Core/Command/Apps/CheckCodeTest.php +++ b/tests/Core/Command/Apps/CheckCodeTest.php @@ -36,9 +36,10 @@ class CheckCodeTest extends TestCase { private $commandTester; /** - * @expectedException \RuntimeException */ public function testWrongAppId() { + $this->expectException(\RuntimeException::class); + $command = new CheckCode(new InfoParser, \OC::$server->getAppManager()); $this->commandTester = new CommandTester($command); $this->commandTester->execute(['app-id' => 'hui-buh']); diff --git a/tests/Core/Command/Background/Queue/DeleteTest.php b/tests/Core/Command/Background/Queue/DeleteTest.php index fabd3a3b38a4..7975583a74be 100644 --- a/tests/Core/Command/Background/Queue/DeleteTest.php +++ b/tests/Core/Command/Background/Queue/DeleteTest.php @@ -38,7 +38,7 @@ class DeleteTest extends TestCase { /** @var IJobList */ private $jobList; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->jobList = $this->createMock(IJobList::class); @@ -60,7 +60,7 @@ public function testCommandInput($jobId, $expectedOutput) { $input = ['Job ID' => $jobId]; $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function providesJobIds() { diff --git a/tests/Core/Command/Background/Queue/ExecuteTest.php b/tests/Core/Command/Background/Queue/ExecuteTest.php index cafd2c7777b4..3981de03ee1c 100644 --- a/tests/Core/Command/Background/Queue/ExecuteTest.php +++ b/tests/Core/Command/Background/Queue/ExecuteTest.php @@ -45,7 +45,7 @@ class ExecuteTest extends TestCase { /** @var IJob[] */ private $jobById = []; - public function setUp() { + public function setUp(): void { parent::setUp(); $normalJob = $this->createMock(IJob::class); diff --git a/tests/Core/Command/Background/Queue/StatusTest.php b/tests/Core/Command/Background/Queue/StatusTest.php index 61a2c5dad5bf..8f5c208e7773 100644 --- a/tests/Core/Command/Background/Queue/StatusTest.php +++ b/tests/Core/Command/Background/Queue/StatusTest.php @@ -40,7 +40,7 @@ class StatusTest extends TestCase { /** @var IJobList */ private $jobList; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->jobList = $this->createMock(IJobList::class); @@ -67,7 +67,7 @@ public function testCommandInput() { +--------+------------------------------------+---------------------------+---------------+ EOS; - $this->assertContains($expected, $output); + $this->assertStringContainsString($expected, $output); } public function testJobWithArray() { @@ -88,6 +88,6 @@ public function testJobWithArray() { +--------+------------------------------------+---------------------------+-----------------------+ EOS; - $this->assertContains($expected, $output); + $this->assertStringContainsString($expected, $output); } } diff --git a/tests/Core/Command/Config/App/DeleteConfigTest.php b/tests/Core/Command/Config/App/DeleteConfigTest.php index c1e59d45302c..9986e9989e37 100644 --- a/tests/Core/Command/Config/App/DeleteConfigTest.php +++ b/tests/Core/Command/Config/App/DeleteConfigTest.php @@ -36,7 +36,7 @@ class DeleteConfigTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder('OCP\IConfig') diff --git a/tests/Core/Command/Config/App/GetConfigTest.php b/tests/Core/Command/Config/App/GetConfigTest.php index f0b31fa7c6ad..a46fd1966f70 100644 --- a/tests/Core/Command/Config/App/GetConfigTest.php +++ b/tests/Core/Command/Config/App/GetConfigTest.php @@ -38,7 +38,7 @@ class GetConfigTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder(IConfig::class) diff --git a/tests/Core/Command/Config/App/SetConfigTest.php b/tests/Core/Command/Config/App/SetConfigTest.php index a84edf1f3df4..b2ee0694293a 100644 --- a/tests/Core/Command/Config/App/SetConfigTest.php +++ b/tests/Core/Command/Config/App/SetConfigTest.php @@ -36,7 +36,7 @@ class SetConfigTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder('OCP\IConfig') diff --git a/tests/Core/Command/Config/ImportTest.php b/tests/Core/Command/Config/ImportTest.php index b5cbbada0ba2..eaf1f8dc88c7 100644 --- a/tests/Core/Command/Config/ImportTest.php +++ b/tests/Core/Command/Config/ImportTest.php @@ -36,7 +36,7 @@ class ImportTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder('OCP\IConfig') diff --git a/tests/Core/Command/Config/ListConfigsTest.php b/tests/Core/Command/Config/ListConfigsTest.php index 954675875c58..f68abd9f2248 100644 --- a/tests/Core/Command/Config/ListConfigsTest.php +++ b/tests/Core/Command/Config/ListConfigsTest.php @@ -39,7 +39,7 @@ class ListConfigsTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $systemConfig = $this->systemConfig = $this->getMockBuilder('OC\SystemConfig') diff --git a/tests/Core/Command/Config/System/DeleteConfigTest.php b/tests/Core/Command/Config/System/DeleteConfigTest.php index eebbf139c5e3..6d159ef45c4a 100644 --- a/tests/Core/Command/Config/System/DeleteConfigTest.php +++ b/tests/Core/Command/Config/System/DeleteConfigTest.php @@ -36,7 +36,7 @@ class DeleteConfigTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $systemConfig = $this->systemConfig = $this->getMockBuilder('OC\SystemConfig') diff --git a/tests/Core/Command/Config/System/GetConfigTest.php b/tests/Core/Command/Config/System/GetConfigTest.php index 191de04d7705..514479ee5f13 100644 --- a/tests/Core/Command/Config/System/GetConfigTest.php +++ b/tests/Core/Command/Config/System/GetConfigTest.php @@ -37,7 +37,7 @@ class GetConfigTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $systemConfig = $this->systemConfig = $this->getMockBuilder(SystemConfig::class) diff --git a/tests/Core/Command/Config/System/SetConfigTest.php b/tests/Core/Command/Config/System/SetConfigTest.php index b87dfb313f2e..e8642bbbac0a 100644 --- a/tests/Core/Command/Config/System/SetConfigTest.php +++ b/tests/Core/Command/Config/System/SetConfigTest.php @@ -36,7 +36,7 @@ class SetConfigTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $systemConfig = $this->systemConfig = $this->getMockBuilder('OC\SystemConfig') @@ -97,9 +97,10 @@ public function setUpdateOnlyProvider() { /** * @dataProvider setUpdateOnlyProvider - * @expectedException \UnexpectedValueException */ public function testSetUpdateOnly($configNames, $existingData) { + $this->expectException(\UnexpectedValueException::class); + $this->systemConfig->expects($this->never()) ->method('setValue'); $this->systemConfig->method('getValue') @@ -207,9 +208,10 @@ public function castValueInvalidProvider() { /** * @dataProvider castValueInvalidProvider - * @expectedException \InvalidArgumentException */ public function testCastValueInvalid($value, $type) { + $this->expectException(\InvalidArgumentException::class); + $this->invokePrivate($this->command, 'castValue', [$value, $type]); } } diff --git a/tests/Core/Command/Db/ConvertTypeTest.php b/tests/Core/Command/Db/ConvertTypeTest.php index 6dbae8931793..8d968d3b95f4 100644 --- a/tests/Core/Command/Db/ConvertTypeTest.php +++ b/tests/Core/Command/Db/ConvertTypeTest.php @@ -50,7 +50,7 @@ class ConvertTypeTest extends TestCase { /** @var \Doctrine\DBAL\Connection */ private $connection; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->connection = \OC::$server->getDatabaseConnection(); $this->config = $this->getMockBuilder(IConfig::class) @@ -64,9 +64,10 @@ protected function setUp() { } /** - * @expectedException \Doctrine\DBAL\DBALException */ public function testWrongConnectionParams() { + $this->expectException(\Doctrine\DBAL\DBALException::class); + if (!$this->connection->getDatabasePlatform() instanceof \Doctrine\DBAL\Platforms\SqlitePlatform) { $this->markTestSkipped("Test only relevant on Sqlite"); } diff --git a/tests/Core/Command/Encryption/ChangeKeyStorageRootTest.php b/tests/Core/Command/Encryption/ChangeKeyStorageRootTest.php index 225cdb801706..c4e60f4a9a94 100644 --- a/tests/Core/Command/Encryption/ChangeKeyStorageRootTest.php +++ b/tests/Core/Command/Encryption/ChangeKeyStorageRootTest.php @@ -60,7 +60,7 @@ class ChangeKeyStorageRootTest extends TestCase { /** @var \OCP\UserInterface | \PHPUnit\Framework\MockObject\MockObject */ protected $userInterface; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->view = $this->createMock('\OC\Files\View'); @@ -175,12 +175,13 @@ public function testPrepareNewRoot() { /** * @dataProvider dataTestPrepareNewRootException - * @expectedException \Exception * * @param bool $dirExists * @param bool $couldCreateFile */ public function testPrepareNewRootException($dirExists, $couldCreateFile) { + $this->expectException(\Exception::class); + $this->view->expects($this->once())->method('is_dir')->with('newRoot') ->willReturn($dirExists); $this->view->expects($this->any())->method('file_put_contents')->willReturn($couldCreateFile); @@ -203,11 +204,12 @@ public function nulldir() { /** * @dataProvider nulldir - * @expectedException \Exception - * @expectedExceptionMessage New root folder doesn't exist. Please create the folder or check the permissions and try again. * @param $dirExists */ public function testPrepareNewRootExceptionForNullDir($dirExists) { + $this->expectException(\Exception::class); + $this->expectExceptionMessage('New root folder doesn\'t exist. Please create the folder or check the permissions and try again.'); + $this->view->expects($this->once())->method('is_dir')->with('../../newRoot') ->willReturn($dirExists); $this->invokePrivate($this->changeKeyStorageRoot, 'prepareNewRoot', ['../../newRoot']); @@ -375,9 +377,10 @@ public function testTargetExists() { } /** - * @expectedException \Exception */ public function testTargetExistsException() { + $this->expectException(\Exception::class); + $this->view->expects($this->once())->method('file_exists')->with('path') ->willReturn(true); diff --git a/tests/Core/Command/Encryption/DecryptAllTest.php b/tests/Core/Command/Encryption/DecryptAllTest.php index 09e8de1c9173..f87b1a9adfaa 100644 --- a/tests/Core/Command/Encryption/DecryptAllTest.php +++ b/tests/Core/Command/Encryption/DecryptAllTest.php @@ -47,7 +47,7 @@ class DecryptAllTest extends TestCase { /** @var \PHPUnit\Framework\MockObject\MockObject | \OC\Encryption\DecryptAll */ protected $decryptAll; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->getMockBuilder('OCP\IConfig') @@ -175,9 +175,10 @@ public function dataTestExecute() { } /** - * @expectedException \Exception */ public function testExecuteFailure() { + $this->expectException(\Exception::class); + $instance = new DecryptAll( $this->encryptionManager, $this->appManager, diff --git a/tests/Core/Command/Encryption/DisableTest.php b/tests/Core/Command/Encryption/DisableTest.php index fd5bbfb7e4c6..74a42767c6d0 100644 --- a/tests/Core/Command/Encryption/DisableTest.php +++ b/tests/Core/Command/Encryption/DisableTest.php @@ -35,7 +35,7 @@ class DisableTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder('OCP\IConfig') diff --git a/tests/Core/Command/Encryption/EnableTest.php b/tests/Core/Command/Encryption/EnableTest.php index 607f51bf33ce..b8a548515d51 100644 --- a/tests/Core/Command/Encryption/EnableTest.php +++ b/tests/Core/Command/Encryption/EnableTest.php @@ -37,7 +37,7 @@ class EnableTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder('OCP\IConfig') diff --git a/tests/Core/Command/Encryption/EncryptAllTest.php b/tests/Core/Command/Encryption/EncryptAllTest.php index 5a58c390127a..abc6e0cc1d28 100644 --- a/tests/Core/Command/Encryption/EncryptAllTest.php +++ b/tests/Core/Command/Encryption/EncryptAllTest.php @@ -50,7 +50,7 @@ class EncryptAllTest extends TestCase { /** @var EncryptAll */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->config = $this->getMockBuilder('OCP\IConfig') @@ -125,9 +125,10 @@ public function dataTestExecute() { } /** - * @expectedException \Exception */ public function testExecuteException() { + $this->expectException(\Exception::class); + $command = new EncryptAll($this->encryptionManager, $this->appManager, $this->config, $this->questionHelper); $this->encryptionManager->expects($this->once())->method('isEnabled')->willReturn(false); $this->encryptionManager->expects($this->never())->method('getEncryptionModule'); diff --git a/tests/Core/Command/Encryption/SetDefaultModuleTest.php b/tests/Core/Command/Encryption/SetDefaultModuleTest.php index f1cebf495d75..68cb47f6b449 100644 --- a/tests/Core/Command/Encryption/SetDefaultModuleTest.php +++ b/tests/Core/Command/Encryption/SetDefaultModuleTest.php @@ -35,7 +35,7 @@ class SetDefaultModuleTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $manager = $this->manager = $this->getMockBuilder('OCP\Encryption\IManager') diff --git a/tests/Core/Command/Group/AddMemberTest.php b/tests/Core/Command/Group/AddMemberTest.php index e3b92494e504..275fbae84ea6 100644 --- a/tests/Core/Command/Group/AddMemberTest.php +++ b/tests/Core/Command/Group/AddMemberTest.php @@ -37,7 +37,7 @@ class AddMemberTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new AddMember(\OC::$server->getGroupManager(), \OC::$server->getUserManager()); @@ -56,7 +56,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/Group/AddTest.php b/tests/Core/Command/Group/AddTest.php index ee2c18d33f2e..2cb42046a308 100644 --- a/tests/Core/Command/Group/AddTest.php +++ b/tests/Core/Command/Group/AddTest.php @@ -34,7 +34,7 @@ class AddTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new Add(\OC::$server->getGroupManager()); @@ -51,7 +51,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/Group/DeleteTest.php b/tests/Core/Command/Group/DeleteTest.php index 021642420e7c..e22cfc0455b9 100644 --- a/tests/Core/Command/Group/DeleteTest.php +++ b/tests/Core/Command/Group/DeleteTest.php @@ -35,7 +35,7 @@ class DeleteTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $groupManager = $this->groupManager = $this->getMockBuilder('OCP\IGroupManager') diff --git a/tests/Core/Command/Group/ListGroupMembersTest.php b/tests/Core/Command/Group/ListGroupMembersTest.php index 8e9ac9a46067..bd666f7bd9cf 100644 --- a/tests/Core/Command/Group/ListGroupMembersTest.php +++ b/tests/Core/Command/Group/ListGroupMembersTest.php @@ -37,7 +37,7 @@ class ListGroupMembersTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new ListGroupMembers(\OC::$server->getGroupManager()); @@ -56,7 +56,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/Group/ListGroupsTest.php b/tests/Core/Command/Group/ListGroupsTest.php index 6c9c75a510b4..24b38b7684c1 100644 --- a/tests/Core/Command/Group/ListGroupsTest.php +++ b/tests/Core/Command/Group/ListGroupsTest.php @@ -34,7 +34,7 @@ class ListGroupsTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new ListGroups(\OC::$server->getGroupManager()); @@ -51,7 +51,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/Group/RemoveMemberTest.php b/tests/Core/Command/Group/RemoveMemberTest.php index 57a519f5700c..2eb71b8abe43 100644 --- a/tests/Core/Command/Group/RemoveMemberTest.php +++ b/tests/Core/Command/Group/RemoveMemberTest.php @@ -37,7 +37,7 @@ class RemoveMemberTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new RemoveMember(\OC::$server->getGroupManager(), \OC::$server->getUserManager()); @@ -57,7 +57,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/Log/ManageTest.php b/tests/Core/Command/Log/ManageTest.php index 5259a57eac58..d776cf954862 100644 --- a/tests/Core/Command/Log/ManageTest.php +++ b/tests/Core/Command/Log/ManageTest.php @@ -35,7 +35,7 @@ class ManageTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder('OCP\IConfig') @@ -84,16 +84,18 @@ public function testChangeTimezone() { } /** - * @expectedException \InvalidArgumentException */ public function testValidateBackend() { + $this->expectException(\InvalidArgumentException::class); + self::invokePrivate($this->command, 'validateBackend', ['notabackend']); } /** - * @expectedException \Exception */ public function testValidateTimezone() { + $this->expectException(\Exception::class); + // this might need to be changed when humanity colonises Mars self::invokePrivate($this->command, 'validateTimezone', ['Mars/OlympusMons']); } @@ -119,9 +121,10 @@ public function testConvertLevelString($levelString, $expectedInt) { } /** - * @expectedException \InvalidArgumentException */ public function testConvertLevelStringInvalid() { + $this->expectException(\InvalidArgumentException::class); + self::invokePrivate($this->command, 'convertLevelString', ['abc']); } @@ -144,9 +147,10 @@ public function testConvertLevelNumber($levelNum, $expectedString) { } /** - * @expectedException \InvalidArgumentException */ public function testConvertLevelNumberInvalid() { + $this->expectException(\InvalidArgumentException::class); + self::invokePrivate($this->command, 'convertLevelNumber', [11]); } diff --git a/tests/Core/Command/Log/OwnCloudTest.php b/tests/Core/Command/Log/OwnCloudTest.php index 5c5ae8b56aac..11713ff51c38 100644 --- a/tests/Core/Command/Log/OwnCloudTest.php +++ b/tests/Core/Command/Log/OwnCloudTest.php @@ -35,7 +35,7 @@ class OwnCloudTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder('OCP\IConfig') diff --git a/tests/Core/Command/Maintenance/DataFingerprintTest.php b/tests/Core/Command/Maintenance/DataFingerprintTest.php index 29777cb9e1c1..0467c3c7108e 100644 --- a/tests/Core/Command/Maintenance/DataFingerprintTest.php +++ b/tests/Core/Command/Maintenance/DataFingerprintTest.php @@ -49,7 +49,7 @@ public function providesAnswers() { ]; } - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->config = $this->createMock(IConfig::class); @@ -84,6 +84,9 @@ public function testSetFingerPrint($expectToLog, $answer) { $this->commandTester->setInputs([$answer]); $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains("Do you want to set the data fingerprint?", $output); + $this->assertStringContainsString( + "Do you want to set the data fingerprint?", + $output + ); } } diff --git a/tests/Core/Command/Maintenance/Mimetype/UpdateDBTest.php b/tests/Core/Command/Maintenance/Mimetype/UpdateDBTest.php index bcb527eaf540..621e2624f8ac 100644 --- a/tests/Core/Command/Maintenance/Mimetype/UpdateDBTest.php +++ b/tests/Core/Command/Maintenance/Mimetype/UpdateDBTest.php @@ -40,7 +40,7 @@ class UpdateDBTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->detector = $this->getMockBuilder('OC\Files\Type\Detection') diff --git a/tests/Core/Command/Maintenance/RepairTest.php b/tests/Core/Command/Maintenance/RepairTest.php index 37b318f61eb8..ef3f92f56ff0 100644 --- a/tests/Core/Command/Maintenance/RepairTest.php +++ b/tests/Core/Command/Maintenance/RepairTest.php @@ -36,7 +36,7 @@ class RepairTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $application = new Application( @@ -54,7 +54,7 @@ protected function setUp() { $this->commandTester = new CommandTester($command); } - protected function tearDown() { + protected function tearDown(): void { parent::tearDown(); \OC::$server->getConfig()->setSystemValue('maintenance', false); } @@ -71,7 +71,7 @@ public function testCommandInput($input, $maintenanceMode, $returnValue, $expect $result = $this->commandTester->execute($input); $this->assertEquals($result, $returnValue); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/Maintenance/SingleUserTest.php b/tests/Core/Command/Maintenance/SingleUserTest.php index fb8efaf0a579..194fa44eedfc 100644 --- a/tests/Core/Command/Maintenance/SingleUserTest.php +++ b/tests/Core/Command/Maintenance/SingleUserTest.php @@ -35,7 +35,7 @@ class SingleUserTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $config = $this->config = $this->getMockBuilder('OCP\IConfig') diff --git a/tests/Core/Command/System/CronTest.php b/tests/Core/Command/System/CronTest.php index 81c5a51b5ecf..e71096015736 100644 --- a/tests/Core/Command/System/CronTest.php +++ b/tests/Core/Command/System/CronTest.php @@ -51,7 +51,7 @@ class CronTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->config = $this->createMock(IConfig::class); @@ -68,7 +68,10 @@ public function testMaintenanceMode() { $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains('We are in maintenance mode, skipping cron', $output); + $this->assertStringContainsString( + 'We are in maintenance mode, skipping cron', + $output + ); } public function testSingleuser() { @@ -80,7 +83,10 @@ public function testSingleuser() { $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains('We are in admin only mode, skipping cron', $output); + $this->assertStringContainsString( + 'We are in admin only mode, skipping cron', + $output + ); } public function testCronDisabled() { @@ -93,7 +99,10 @@ public function testCronDisabled() { $this->commandTester->execute([]); $output = $this->commandTester->getDisplay(); - $this->assertContains('Background Jobs are disabled!', $output); + $this->assertStringContainsString( + 'Background Jobs are disabled!', + $output + ); } public function testCronRun() { @@ -113,6 +122,9 @@ public function testCronRun() { $this->commandTester->execute(['--progress' => true]); $output = $this->commandTester->getDisplay(); - $this->assertContains('1 [->--------------------------]', $output); + $this->assertStringContainsString( + '1 [->--------------------------]', + $output + ); } } diff --git a/tests/Core/Command/TwoFactorAuth/DisableTest.php b/tests/Core/Command/TwoFactorAuth/DisableTest.php index 75ed6a13a20d..ef9bce00d7c8 100644 --- a/tests/Core/Command/TwoFactorAuth/DisableTest.php +++ b/tests/Core/Command/TwoFactorAuth/DisableTest.php @@ -37,7 +37,7 @@ class DisableTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new Disable(\OC::$server->getTwoFactorAuthManager(), \OC::$server->getUserManager()); @@ -54,7 +54,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/TwoFactorAuth/EnableTest.php b/tests/Core/Command/TwoFactorAuth/EnableTest.php index 041e8af8ee08..ecec04b26999 100644 --- a/tests/Core/Command/TwoFactorAuth/EnableTest.php +++ b/tests/Core/Command/TwoFactorAuth/EnableTest.php @@ -37,7 +37,7 @@ class EnableTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new Enable(\OC::$server->getTwoFactorAuthManager(), \OC::$server->getUserManager()); @@ -54,7 +54,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/User/AddTest.php b/tests/Core/Command/User/AddTest.php index 5f09ee5339b5..3d43f2c121dc 100644 --- a/tests/Core/Command/User/AddTest.php +++ b/tests/Core/Command/User/AddTest.php @@ -39,7 +39,7 @@ class AddTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $application = new Application(\OC::$server->getConfig(), \OC::$server->getEventDispatcher(), \OC::$server->getRequest()); @@ -49,7 +49,7 @@ protected function setUp() { $this->createUser('user1'); } - protected function tearDown() { + protected function tearDown(): void { parent::tearDown(); if (\OC::$server->getUserManager()->get('user2') instanceof User) { \OC::$server->getUserManager()->get('user2')->delete(); @@ -66,7 +66,7 @@ public function testCommandInput($input, $answers, $expectedOutput) { $this->commandTester->setInputs($answers); $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } /** diff --git a/tests/Core/Command/User/DeleteTest.php b/tests/Core/Command/User/DeleteTest.php index ba2a27c67be1..24614cb722a4 100644 --- a/tests/Core/Command/User/DeleteTest.php +++ b/tests/Core/Command/User/DeleteTest.php @@ -36,7 +36,7 @@ class DeleteTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userManager = $this->getMockBuilder('OCP\IUserManager') ->disableOriginalConstructor() @@ -88,7 +88,7 @@ public function testValidUser($deleteSuccess, $expectedOutput) { $this->commandTester->execute(['uid' => 'user']); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function testInvalidUser() { @@ -99,6 +99,9 @@ public function testInvalidUser() { $this->commandTester->execute(['uid' => 'user']); $output = $this->commandTester->getDisplay(); - $this->assertContains("User with uid 'user' does not exist", $output); + $this->assertStringContainsString( + "User with uid 'user' does not exist", + $output + ); } } diff --git a/tests/Core/Command/User/DisableTest.php b/tests/Core/Command/User/DisableTest.php index 9305f3577324..c0a77df60cd3 100644 --- a/tests/Core/Command/User/DisableTest.php +++ b/tests/Core/Command/User/DisableTest.php @@ -37,7 +37,7 @@ class DisableTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new Disable(\OC::$server->getUserManager()); @@ -53,7 +53,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/User/EnableTest.php b/tests/Core/Command/User/EnableTest.php index 5adca7c6e786..b96a47c79471 100644 --- a/tests/Core/Command/User/EnableTest.php +++ b/tests/Core/Command/User/EnableTest.php @@ -37,7 +37,7 @@ class EnableTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new Enable(\OC::$server->getUserManager()); @@ -53,7 +53,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/User/InactiveTest.php b/tests/Core/Command/User/InactiveTest.php index 69854e023022..7d4bfcda58ab 100644 --- a/tests/Core/Command/User/InactiveTest.php +++ b/tests/Core/Command/User/InactiveTest.php @@ -39,7 +39,7 @@ class InactiveTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $userManager = $this->userManager = $this->getMockBuilder('OCP\IUserManager') diff --git a/tests/Core/Command/User/LastSeenTest.php b/tests/Core/Command/User/LastSeenTest.php index 02d6a7b6127a..af147435423d 100644 --- a/tests/Core/Command/User/LastSeenTest.php +++ b/tests/Core/Command/User/LastSeenTest.php @@ -35,7 +35,7 @@ class LastSeenTest extends TestCase { /** @var \Symfony\Component\Console\Command\Command */ protected $command; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $userManager = $this->userManager = $this->getMockBuilder('OCP\IUserManager') diff --git a/tests/Core/Command/User/ListUserGroupsTest.php b/tests/Core/Command/User/ListUserGroupsTest.php index f202c8652876..7bc41218b4d8 100644 --- a/tests/Core/Command/User/ListUserGroupsTest.php +++ b/tests/Core/Command/User/ListUserGroupsTest.php @@ -37,7 +37,7 @@ class ListUserGroupsTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $command = new ListUserGroups(\OC::$server->getUserManager(), \OC::$server->getGroupManager()); @@ -55,7 +55,7 @@ protected function setUp() { public function testCommandInput($input, $expectedOutput) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } public function inputProvider() { diff --git a/tests/Core/Command/User/ListUsersTest.php b/tests/Core/Command/User/ListUsersTest.php index d439d50e622d..5e14a6d04161 100644 --- a/tests/Core/Command/User/ListUsersTest.php +++ b/tests/Core/Command/User/ListUsersTest.php @@ -34,7 +34,7 @@ class ListUsersTest extends TestCase { /** @var CommandTester */ private $commandTester; - protected function setUp() { + protected function setUp(): void { parent::setUp(); \OC::$server->getUserManager()->createUser('testlistuser', 'password'); @@ -42,7 +42,7 @@ protected function setUp() { $this->commandTester = new CommandTester($command); } - protected function tearDown() { + protected function tearDown(): void { parent::tearDown(); \OC::$server->getUserManager()->get('testlistuser')->delete(); } @@ -56,7 +56,7 @@ public function testCommandInput($input, $expectedOutputs) { $this->commandTester->execute($input); $output = $this->commandTester->getDisplay(); foreach ($expectedOutputs as $expectedOutput) { - $this->assertContains($expectedOutput, $output); + $this->assertStringContainsString($expectedOutput, $output); } } diff --git a/tests/Core/Command/User/ModifyTest.php b/tests/Core/Command/User/ModifyTest.php index 15de3a072001..7d66115d7e91 100644 --- a/tests/Core/Command/User/ModifyTest.php +++ b/tests/Core/Command/User/ModifyTest.php @@ -50,7 +50,7 @@ class ModifyTest extends TestCase { /** @var OutputInterface | \PHPUnit\Framework\MockObject\MockObject */ protected $consoleOutput; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userManager = $this->createMock(IUserManager::class); diff --git a/tests/Core/Command/User/ResetPasswordTest.php b/tests/Core/Command/User/ResetPasswordTest.php index 1814b05ed67b..e068b5d070d3 100644 --- a/tests/Core/Command/User/ResetPasswordTest.php +++ b/tests/Core/Command/User/ResetPasswordTest.php @@ -51,7 +51,7 @@ class ResetPasswordTest extends TestCase { private $lostController; /** @var ResetPassword */ private $resetPassword; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userManager = $this->createMock(IUserManager::class); diff --git a/tests/Core/Command/User/SettingTest.php b/tests/Core/Command/User/SettingTest.php index 84287731ffd4..ad4c872a6580 100644 --- a/tests/Core/Command/User/SettingTest.php +++ b/tests/Core/Command/User/SettingTest.php @@ -36,7 +36,7 @@ class SettingTest extends TestCase { /** @var \Symfony\Component\Console\Output\OutputInterface|\PHPUnit\Framework\MockObject\MockObject */ protected $consoleOutput; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->userManager = $this->getMockBuilder('OCP\IUserManager') diff --git a/tests/Core/Controller/AvatarControllerTest.php b/tests/Core/Controller/AvatarControllerTest.php index b0e569d296e2..485147f85b29 100644 --- a/tests/Core/Controller/AvatarControllerTest.php +++ b/tests/Core/Controller/AvatarControllerTest.php @@ -74,7 +74,7 @@ class AvatarControllerTest extends TestCase { /** @var ILogger | \PHPUnit\Framework\MockObject\MockObject */ private $logger; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->createUser('userid', 'pass'); $this->loginAsUser('userid'); @@ -125,7 +125,7 @@ protected function setUp() { $this->avatarFile->expects($this->any())->method('getEtag')->willReturn('my etag'); } - public function tearDown() { + public function tearDown(): void { $this->logout(); parent::tearDown(); } diff --git a/tests/Core/Controller/CronControllerTest.php b/tests/Core/Controller/CronControllerTest.php index 84099cb3e224..0924cc98f633 100644 --- a/tests/Core/Controller/CronControllerTest.php +++ b/tests/Core/Controller/CronControllerTest.php @@ -48,7 +48,7 @@ class CronControllerTest extends TestCase { /** @var IRequest | \PHPUnit_Framework_MockObject_MockObject */ private $request; - protected function setUp() { + protected function setUp(): void { $this->request = $this->createMock(IRequest::class); $this->config = $this->createMock(IConfig::class); $this->logger = $this->createMock(ILogger::class); diff --git a/tests/Core/Controller/LoginControllerTest.php b/tests/Core/Controller/LoginControllerTest.php index c45c1e95ea53..462aef91e246 100644 --- a/tests/Core/Controller/LoginControllerTest.php +++ b/tests/Core/Controller/LoginControllerTest.php @@ -53,7 +53,7 @@ class LoginControllerTest extends TestCase { /** @var Manager | \PHPUnit\Framework\MockObject\MockObject */ private $twoFactorManager; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->createMock(IRequest::class); $this->userManager = $this->createMock(IUserManager::class); diff --git a/tests/Core/Controller/LostControllerTest.php b/tests/Core/Controller/LostControllerTest.php index d668592c67ee..4ccb0d05af71 100644 --- a/tests/Core/Controller/LostControllerTest.php +++ b/tests/Core/Controller/LostControllerTest.php @@ -71,7 +71,7 @@ class LostControllerTest extends TestCase { /** @var Session */ private $userSession; - protected function setUp() { + protected function setUp(): void { $this->existingUser = $this->getMockBuilder('OCP\IUser') ->disableOriginalConstructor()->getMock(); diff --git a/tests/Core/Controller/TokenControllerTest.php b/tests/Core/Controller/TokenControllerTest.php index 8a79225bec4a..945040aeb865 100644 --- a/tests/Core/Controller/TokenControllerTest.php +++ b/tests/Core/Controller/TokenControllerTest.php @@ -38,7 +38,7 @@ class TokenControllerTest extends TestCase { private $twoFactorAuthManager; private $secureRandom; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->request = $this->createMock('\OCP\IRequest'); diff --git a/tests/Core/Controller/TwoFactorChallengeControllerTest.php b/tests/Core/Controller/TwoFactorChallengeControllerTest.php index 4f0a4010960a..071a289e6306 100644 --- a/tests/Core/Controller/TwoFactorChallengeControllerTest.php +++ b/tests/Core/Controller/TwoFactorChallengeControllerTest.php @@ -52,7 +52,7 @@ class TwoFactorChallengeControllerTest extends TestCase { /** @var TwoFactorChallengeController|MockObject */ private $controller; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->request = $this->createMock(IRequest::class); diff --git a/tests/Core/Middleware/AccountModuleMiddlewareTest.php b/tests/Core/Middleware/AccountModuleMiddlewareTest.php index ef8cad4b31d1..217a4a1804bd 100644 --- a/tests/Core/Middleware/AccountModuleMiddlewareTest.php +++ b/tests/Core/Middleware/AccountModuleMiddlewareTest.php @@ -50,7 +50,7 @@ class AccountModuleMiddlewareTest extends TestCase { /** @var AccountModuleMiddleware */ private $middleware; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->logger = $this->createMock(ILogger::class); @@ -132,9 +132,10 @@ public function testBeforeControllerNotLoggedIn() { } /** - * @expectedException \UnexpectedValueException */ public function testBeforeControllerNoUserInSession() { + $this->expectException(\UnexpectedValueException::class); + $this->reflector->expects($this->once()) ->method('hasAnnotation') ->with('PublicPage') @@ -172,9 +173,10 @@ public function testBeforeControllerAccountUpToDate() { } /** - * @expectedException \OCP\Authentication\Exceptions\AccountCheckException */ public function testBeforeControllerAccountNeedsUpdate() { + $this->expectException(\OCP\Authentication\Exceptions\AccountCheckException::class); + $this->reflector->expects($this->once()) ->method('hasAnnotation') ->with('PublicPage') @@ -204,10 +206,11 @@ public function testAfterExceptionAccountNeedsUpdate() { } /** - * @expectedException \Exception - * @expectedExceptionMessage testAfterException */ public function testAfterException() { + $this->expectException(\Exception::class); + $this->expectExceptionMessage('testAfterException'); + $ex = new \Exception('testAfterException'); $this->middleware->afterException(null, null, $ex); } diff --git a/tests/Core/Middleware/TwoFactorMiddlewareTest.php b/tests/Core/Middleware/TwoFactorMiddlewareTest.php index 366d94ce47f0..cd97aae0f9f7 100644 --- a/tests/Core/Middleware/TwoFactorMiddlewareTest.php +++ b/tests/Core/Middleware/TwoFactorMiddlewareTest.php @@ -53,7 +53,7 @@ class TwoFactorMiddlewareTest extends TestCase { /** @var TwoFactorMiddleware */ private $middleware; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->twoFactorManager = $this->getMockBuilder(Manager::class) @@ -123,9 +123,10 @@ public function testBeforeControllerNoTwoFactorCheckNeeded() { } /** - * @expectedException \OC\Authentication\Exceptions\TwoFactorAuthRequiredException */ public function testBeforeControllerTwoFactorAuthRequired() { + $this->expectException(\OC\Authentication\Exceptions\TwoFactorAuthRequiredException::class); + $user = $this->createMock('\OCP\IUser'); $this->reflector->expects($this->once()) @@ -150,9 +151,10 @@ public function testBeforeControllerTwoFactorAuthRequired() { } /** - * @expectedException \OC\Authentication\Exceptions\UserAlreadyLoggedInException */ public function testBeforeControllerUserAlreadyLoggedIn() { + $this->expectException(\OC\Authentication\Exceptions\UserAlreadyLoggedInException::class); + $user = $this->createMock('\OCP\IUser'); $this->reflector->expects($this->once()) diff --git a/tests/Settings/Controller/AppSettingsControllerTest.php b/tests/Settings/Controller/AppSettingsControllerTest.php index 254200242662..9beffa9f753f 100644 --- a/tests/Settings/Controller/AppSettingsControllerTest.php +++ b/tests/Settings/Controller/AppSettingsControllerTest.php @@ -45,7 +45,7 @@ class AppSettingsControllerTest extends TestCase { /** @var IAppManager */ private $appManager; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->getMockBuilder(IRequest::class) diff --git a/tests/Settings/Controller/AuthSettingsControllerTest.php b/tests/Settings/Controller/AuthSettingsControllerTest.php index 99cb8ec36a74..bb67f5752dbc 100644 --- a/tests/Settings/Controller/AuthSettingsControllerTest.php +++ b/tests/Settings/Controller/AuthSettingsControllerTest.php @@ -42,7 +42,7 @@ class AuthSettingsControllerTest extends TestCase { private $secureRandom; private $uid; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->request = $this->createMock('\OCP\IRequest'); diff --git a/tests/Settings/Controller/CertificateControllerTest.php b/tests/Settings/Controller/CertificateControllerTest.php index b74802eb569b..49c7490f385a 100644 --- a/tests/Settings/Controller/CertificateControllerTest.php +++ b/tests/Settings/Controller/CertificateControllerTest.php @@ -48,7 +48,7 @@ class CertificateControllerTest extends \Test\TestCase { /** @var ICertificateManager */ private $systemCertificateManager; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->createMock('\OCP\IRequest'); diff --git a/tests/Settings/Controller/CheckSetupControllerTest.php b/tests/Settings/Controller/CheckSetupControllerTest.php index 9bb2143e9d9a..cb2c096a5c8a 100644 --- a/tests/Settings/Controller/CheckSetupControllerTest.php +++ b/tests/Settings/Controller/CheckSetupControllerTest.php @@ -60,7 +60,7 @@ class CheckSetupControllerTest extends TestCase { /** @var Checker | \PHPUnit\Framework\MockObject\MockObject */ private $checker; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->getMockBuilder('\OCP\IRequest') diff --git a/tests/Settings/Controller/CorsControllerTest.php b/tests/Settings/Controller/CorsControllerTest.php index 94b6a472efc9..09484f04d113 100644 --- a/tests/Settings/Controller/CorsControllerTest.php +++ b/tests/Settings/Controller/CorsControllerTest.php @@ -56,7 +56,7 @@ class CorsControllerTest extends TestCase { /** @var IUser */ private $userSession; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->request = $this->createMock(IRequest::class); diff --git a/tests/Settings/Controller/GroupsControllerTest.php b/tests/Settings/Controller/GroupsControllerTest.php index d115d64c8909..ecefa264134d 100644 --- a/tests/Settings/Controller/GroupsControllerTest.php +++ b/tests/Settings/Controller/GroupsControllerTest.php @@ -27,7 +27,7 @@ class GroupsControllerTest extends \Test\TestCase { /** @var GroupsController */ private $groupsController; - protected function setUp() { + protected function setUp(): void { $app = new Application(); $this->container = $app->getContainer(); $this->container['AppName'] = 'settings'; diff --git a/tests/Settings/Controller/LegalControllerTest.php b/tests/Settings/Controller/LegalControllerTest.php index 7acdeccb7cb7..3548cd8dc07f 100644 --- a/tests/Settings/Controller/LegalControllerTest.php +++ b/tests/Settings/Controller/LegalControllerTest.php @@ -39,7 +39,7 @@ class LegalSettingsControllerTest extends \Test\TestCase { */ private $legalSettingsController; - protected function setUp() { + protected function setUp(): void { $app = new Application(); $this->container = $app->getContainer(); $this->container['Config'] = $this->getMockBuilder(IConfig::class) diff --git a/tests/Settings/Controller/LogSettingsControllerTest.php b/tests/Settings/Controller/LogSettingsControllerTest.php index cae35eb97221..a179fca7d7aa 100644 --- a/tests/Settings/Controller/LogSettingsControllerTest.php +++ b/tests/Settings/Controller/LogSettingsControllerTest.php @@ -24,7 +24,7 @@ class LogSettingsControllerTest extends \Test\TestCase { /** @var LogSettingsController */ private $logSettingsController; - protected function setUp() { + protected function setUp(): void { $app = new Application(); $this->container = $app->getContainer(); $this->container['Config'] = $this->getMockBuilder('\OCP\IConfig') diff --git a/tests/Settings/Controller/MailSettingsControllerTest.php b/tests/Settings/Controller/MailSettingsControllerTest.php index 6256730ea822..e8c2eeac2433 100644 --- a/tests/Settings/Controller/MailSettingsControllerTest.php +++ b/tests/Settings/Controller/MailSettingsControllerTest.php @@ -18,7 +18,7 @@ class MailSettingsControllerTest extends \Test\TestCase { private $container; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $app = new Application(); diff --git a/tests/Settings/Controller/SettingsPageControllerTest.php b/tests/Settings/Controller/SettingsPageControllerTest.php index 02fdd5785470..a6d0f25fb1a4 100644 --- a/tests/Settings/Controller/SettingsPageControllerTest.php +++ b/tests/Settings/Controller/SettingsPageControllerTest.php @@ -46,7 +46,7 @@ class SettingsPageControllerTest extends TestCase { /** @var IFactory */ protected $lfactory; - protected function setUp() { + protected function setUp(): void { parent::setUp(); $this->request = $this->getMockBuilder(IRequest::class)->getMock(); @@ -102,7 +102,7 @@ public function testGetPersonalAsUser() { $this->assertArrayHasKey('adminNav', $response->getParams()); $this->assertEmpty($response->getParams()['adminNav']); $this->assertArrayHasKey('panels', $response->getParams()); - $this->assertContains('testSectionID', $response->getParams()['personalNav'][0]['id']); + $this->assertStringContainsString('testSectionID', $response->getParams()['personalNav'][0]['id']); } public function testGetPersonalAsAdmin() { @@ -148,7 +148,7 @@ public function testGetPersonalAsAdmin() { $this->assertArrayHasKey('icon', $response->getParams()['personalNav'][0]); $this->assertArrayHasKey('link', $response->getParams()['personalNav'][0]); $this->assertArrayHasKey('id', $response->getParams()['personalNav'][0]); - $this->assertContains('testSectionID', $response->getParams()['personalNav'][0]['id']); - $this->assertContains('testAdminSectionID', $response->getParams()['adminNav'][0]['id']); + $this->assertStringContainsString('testSectionID', $response->getParams()['personalNav'][0]['id']); + $this->assertStringContainsString('testAdminSectionID', $response->getParams()['adminNav'][0]['id']); } } diff --git a/tests/Settings/Controller/UsersControllerTest.php b/tests/Settings/Controller/UsersControllerTest.php index 289802cab7d7..25e1501e0bf6 100644 --- a/tests/Settings/Controller/UsersControllerTest.php +++ b/tests/Settings/Controller/UsersControllerTest.php @@ -45,7 +45,7 @@ class UsersControllerTest extends \Test\TestCase { /** @var \OCP\AppFramework\IAppContainer */ private $container; - protected function setUp() { + protected function setUp(): void { $app = new Application(); $this->container = $app->getContainer(); $this->container['AppName'] = 'settings'; diff --git a/tests/Settings/Middleware/SubadminMiddlewareTest.php b/tests/Settings/Middleware/SubadminMiddlewareTest.php index 46fa803aac5b..8bc5e1943845 100644 --- a/tests/Settings/Middleware/SubadminMiddlewareTest.php +++ b/tests/Settings/Middleware/SubadminMiddlewareTest.php @@ -32,7 +32,7 @@ class SubadminMiddlewareTest extends \Test\TestCase { /** @var Controller */ private $controller; - protected function setUp() { + protected function setUp(): void { $this->reflector = $this->getMockBuilder('\OC\AppFramework\Utility\ControllerMethodReflector') ->disableOriginalConstructor()->getMock(); $this->controller = $this->getMockBuilder('\OCP\AppFramework\Controller') @@ -43,9 +43,10 @@ protected function setUp() { } /** - * @expectedException \OC\AppFramework\Middleware\Security\Exceptions\NotSubadminException */ public function testBeforeControllerAsUserWithExemption() { + $this->expectException(\OC\AppFramework\Middleware\Security\Exceptions\NotSubadminException::class); + $this->reflector ->expects($this->once()) ->method('hasAnnotation') @@ -88,9 +89,10 @@ public function testAfterNotAdminException() { } /** - * @expectedException \Exception */ public function testAfterRegularException() { + $this->expectException(\Exception::class); + $expectedResponse = new TemplateResponse('core', '403', [], 'guest'); $expectedResponse->setStatus(403); $this->subadminMiddleware->afterException($this->controller, 'foo', new \Exception()); diff --git a/tests/Settings/Panels/Admin/AppsTest.php b/tests/Settings/Panels/Admin/AppsTest.php index 51bb0a1a0440..175180eb9dcb 100644 --- a/tests/Settings/Panels/Admin/AppsTest.php +++ b/tests/Settings/Panels/Admin/AppsTest.php @@ -23,7 +23,7 @@ class AppsTest extends \Test\TestCase { /** @var IConfig */ private $config; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->getMockBuilder(IConfig::class)->getMock(); $this->panel = new Apps($this->config); @@ -34,11 +34,11 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); } public function testGetPanel() { $templateHtml = $this->panel->getPanel()->fetchPage(); - $this->assertContains('
', $templateHtml); + $this->assertStringContainsString('
', $templateHtml); } } diff --git a/tests/Settings/Panels/Admin/BackgroundJobsTest.php b/tests/Settings/Panels/Admin/BackgroundJobsTest.php index dbd235a64cf5..ca48c139ac4d 100644 --- a/tests/Settings/Panels/Admin/BackgroundJobsTest.php +++ b/tests/Settings/Panels/Admin/BackgroundJobsTest.php @@ -24,7 +24,7 @@ class BackgroundJobsTest extends \Test\TestCase { /** @var IConfig */ private $config; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config =$this->getMockBuilder(IConfig::class)->getMock(); $this->panel = new BackgroundJobs($this->config); @@ -35,7 +35,7 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); $this->assertGreaterThan(-100, $this->panel->getPriority()); $this->assertLessThan(100, $this->panel->getPriority()); } @@ -46,6 +46,6 @@ public function testGetPanel() { // Set cron to 10 mins ago, ajax mode $this->config->expects($this->exactly(2))->method('getAppValue')->willReturn(\time()-10*60, 'ajax'); $templateHtml = $this->panel->getPanel()->fetchPage(); - $this->assertContains('', $templateHtml); + $this->assertStringContainsString('', $templateHtml); } } diff --git a/tests/Settings/Panels/Admin/CertificatesTest.php b/tests/Settings/Panels/Admin/CertificatesTest.php index 1d434615c1e5..8489f79bba8f 100644 --- a/tests/Settings/Panels/Admin/CertificatesTest.php +++ b/tests/Settings/Panels/Admin/CertificatesTest.php @@ -30,7 +30,7 @@ class CertificatesTest extends \Test\TestCase { /** @var ICertificateManager */ private $certManager; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->urlGenerator =$this->getMockBuilder(IURLGenerator::class)->getMock(); $this->config = $this->getMockBuilder(IConfig::class)->getMock(); @@ -43,7 +43,7 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); $this->assertGreaterThan(-100, $this->panel->getPriority()); $this->assertLessThan(100, $this->panel->getPriority()); } @@ -64,10 +64,10 @@ public function testGetPanel() { $this->certManager->expects($this->once())->method('listCertificates')->willReturn([$mockCert]); $this->urlGenerator->expects($this->once())->method('linkToRoute'); $templateHtml = $this->panel->getPanel()->fetchPage(); - $this->assertContains('issueOrg', $templateHtml); - $this->assertContains('issuer', $templateHtml); - $this->assertContains('commonname', $templateHtml); - $this->assertContains('org', $templateHtml); + $this->assertStringContainsString('issueOrg', $templateHtml); + $this->assertStringContainsString('issuer', $templateHtml); + $this->assertStringContainsString('commonname', $templateHtml); + $this->assertStringContainsString('org', $templateHtml); } public function testGetPanelNotEnabled() { diff --git a/tests/Settings/Panels/Admin/EncryptionTest.php b/tests/Settings/Panels/Admin/EncryptionTest.php index bee48b0a8a40..fc0a25979c2d 100644 --- a/tests/Settings/Panels/Admin/EncryptionTest.php +++ b/tests/Settings/Panels/Admin/EncryptionTest.php @@ -20,7 +20,7 @@ class EncryptionTest extends \Test\TestCase { /** @var Encryption */ private $panel; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->panel = new Encryption(); } @@ -30,13 +30,13 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); $this->assertGreaterThan(-100, $this->panel->getPriority()); $this->assertLessThan(100, $this->panel->getPriority()); } public function testGetPanel() { $templateHtml = $this->panel->getPanel()->fetchPage(); - $this->assertContains('org', $templateHtml); + $this->assertStringContainsString('org', $templateHtml); } } diff --git a/tests/Settings/Panels/Admin/FileSharingTest.php b/tests/Settings/Panels/Admin/FileSharingTest.php index 645dee602714..d67c93a5f71c 100644 --- a/tests/Settings/Panels/Admin/FileSharingTest.php +++ b/tests/Settings/Panels/Admin/FileSharingTest.php @@ -27,7 +27,7 @@ class FileSharingTest extends \Test\TestCase { /** @var Helper */ private $helper; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->config = $this->getMockBuilder(IConfig::class)->getMock(); $this->helper = $this->getMockBuilder(Helper::class)->getMock(); @@ -40,13 +40,16 @@ public function testGetSection() { } public function testGetPriority() { - $this->assertInternalType('int', $this->panel->getPriority()); + $this->assertIsInt($this->panel->getPriority()); $this->assertGreaterThan(-100, $this->panel->getPriority()); $this->assertLessThan(100, $this->panel->getPriority()); } public function testGetPanelEnabled() { $templateHtml = $this->panel->getPanel()->fetchPage(); - $this->assertContains('