Skip to content

Commit

Permalink
Merge pull request #1168 from dustin10/php8
Browse files Browse the repository at this point in the history
allow php 8
  • Loading branch information
garak committed Dec 4, 2020
2 parents 8cf8289 + 850c5fd commit efc28ae
Show file tree
Hide file tree
Showing 8 changed files with 31 additions and 37 deletions.
12 changes: 4 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,12 @@ env:

jobs:
include:
- php: 7.2
env: VALIDATE_DOCS=true COMPOSER_FLAGS="--prefer-lowest"
- php: 7.3
env: SYMFONY_VERSION="^4.4.0" WITH_LIIP_IMAGINE=true
env: VALIDATE_DOCS=true COMPOSER_FLAGS="--prefer-lowest"
- php: 7.4
env: VALIDATE_DOCS=false SYMFONY_VERSION="^5.1.0"
- php: nightly
env: COMPOSER_FLAGS="--ignore-platform-reqs"
allow_failures:
- php: nightly
env: SYMFONY_VERSION="^4.4.0" WITH_LIIP_IMAGINE=true
- php: 8.0snapshot
env: VALIDATE_DOCS=false SYMFONY_VERSION="^5.2.0"

before_install:
- if [ -z "$(pecl list | grep -w mongodb)" ]; then pecl install mongodb-1.8.0; fi
Expand Down
8 changes: 4 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,17 +52,17 @@ make test TEST="Tests/Util/FilenameUtilsTest.php"

will allow to tests single Test Classes.

There are 3 environments available: PHP 7.2, 7.3 and 7.4-rc.
Default environment is *PHP 7.3* if you want to execute it against
There are 3 environments available: PHP 7.3, 7.4 and 8.0.
Default environment is *PHP 7.4* if you want to execute it against
other PHP version please use environment variables as this:

```bash
make tests #PHP 7.3 env
TARGET=72 make tests #PHP 7.2 env
TARGET=74 make tests #PHP 7.4 env
TARGET=80 make tests #PHP 8.0 env

make test TEST="Tests/Util/FilenameUtilsTest.php" #PHP 7.3 env
TARGET=72 make test TEST="Tests/Util/FilenameUtilsTest.php" #PHP 7.2 env
TARGET=74 make test TEST="Tests/Util/FilenameUtilsTest.php" #PHP 7.4 env
TARGET=80 make test TEST="Tests/Util/FilenameUtilsTest.php" #PHP 8.0 env
```

2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#/bin/bash

TARGET?=73
TARGET?=74

.PHONY: tests
tests:
Expand Down
18 changes: 9 additions & 9 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
}
],
"require": {
"php": "^7.2",
"php": "^7.3 || ^8.0",
"ext-simplexml": "*",
"jms/metadata": "^2.1",
"jms/metadata": "^2.4",
"symfony/config": "^4.4 || ^5.0",
"symfony/console": "^4.4 || ^5.0",
"symfony/dependency-injection": "^4.4 || ^5.0",
Expand All @@ -31,9 +31,9 @@
},
"require-dev": {
"ext-sqlite3": "*",
"alcaeus/mongo-php-adapter": "^1.1",
"doctrine/doctrine-bundle": "^2.0.3",
"doctrine/mongodb-odm": "^1.2",
"alcaeus/mongo-php-adapter": "^1.2",
"doctrine/doctrine-bundle": "^2.2",
"doctrine/mongodb-odm": "^1.2 || ^2.0",
"doctrine/orm": "^2.7",
"knplabs/knp-gaufrette-bundle": "^0.7",
"kphoen/rusty": "dev-update-php-parser",
Expand All @@ -42,14 +42,14 @@
"matthiasnoback/symfony-dependency-injection-test": "^4.1",
"mikey179/vfsstream": "^1.6",
"oneup/flysystem-bundle": "^3.3",
"phpunit/phpunit": "^8.5",
"phpunit/phpunit": "^9.5",
"symfony/asset": "^4.4 || ^5.0",
"symfony/browser-kit": "^4.4 || ^5.0",
"symfony/css-selector": "^4.4 || ^5.0",
"symfony/doctrine-bridge": "^4.4 || ^5.0",
"symfony/dom-crawler": "^4.4 || ^5.0",
"symfony/framework-bundle": "^4.4 || ^5.0",
"symfony/phpunit-bridge": "^5.1",
"symfony/phpunit-bridge": "^5.2",
"symfony/security-csrf": "^4.4 || ^5.0",
"symfony/translation": "^4.4 || ^5.0",
"symfony/twig-bridge": "^4.4 || ^5.0",
Expand All @@ -72,13 +72,13 @@
},
"config": {
"platform": {
"ext-mongo": "1.6.16"
"ext-mongo": "1.8.2"
},
"sort-packages": true
},
"extra": {
"branch-alias": {
"dev-master": "1.15.x-dev"
"dev-master": "1.x-dev"
}
},
"autoload": {
Expand Down
6 changes: 3 additions & 3 deletions docker/Dockerfile73
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM php:7.3.8-alpine
FROM php:7.3-alpine

ARG MONGODB_VERSION=1.5.3
ARG MONGODB_VERSION=1.8.2

# Install mongo
RUN set -eux; \
Expand Down Expand Up @@ -37,7 +37,7 @@ WORKDIR /srv/vich-uploader
COPY . ./

RUN set -eux; \
composer install --prefer-dist -vvv; \
composer install --prefer-dist -v; \
composer clear-cache

CMD ["/init"]
8 changes: 4 additions & 4 deletions docker/Dockerfile74
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM php:7.4-rc-alpine
FROM php:7.4-alpine

ARG MONGODB_VERSION=1.5.3
ARG MONGODB_VERSION=1.8.2

# Install mongo
RUN set -eux; \
Expand Down Expand Up @@ -33,11 +33,11 @@ RUN mv composer.phar /usr/local/bin/composer
WORKDIR /srv/vich-uploader

# prevent the reinstallation of vendors at every changes in the source code
#COPY composer.json ./

COPY . ./

RUN set -eux; \
composer install --prefer-dist -vvv; \
composer install --prefer-dist -v; \
composer clear-cache

CMD ["/init"]
8 changes: 4 additions & 4 deletions docker/Dockerfile72 → docker/Dockerfile80
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM php:7.2.21-alpine
FROM php:8.0.0-alpine

ARG MONGODB_VERSION=1.5.3
ARG MONGODB_VERSION=1.9.0

# Install mongo
RUN set -eux; \
Expand Down Expand Up @@ -34,11 +34,11 @@ WORKDIR /srv/vich-uploader

# prevent the reinstallation of vendors at every changes in the source code

COPY ./docker/script/runTests.sh ./runTests.sh
#COPY ./docker/script/runTests.sh ./runTests.sh
COPY . ./

RUN set -eux; \
composer install --prefer-dist -vvv; \
composer install --prefer-dist --ignore-platform-reqs; \
composer clear-cache

CMD ["/init"]
6 changes: 2 additions & 4 deletions docs/symfony_support_policy.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,15 @@ Symfony support policy
======================

As indicated by the contraints defined in the `composer.json` file, this bundle
supports Symfony `^4.4|^5.0` in its latest version (`1.12.*`).

Older Symfony versions that are still supported in previous bundle versions (from `1.5.*` to `1.11.*`).
supports Symfony `^4.4 || ^5.0` in its latest versions (>=`1.12.*`).

Only versions still actively maintained by the Symfony core team will be supported by
the maintainers of this bundle. Older versions of Symfony can be still used with previous
versions of this bundle, but there's no active support here.
If you want to get updates on old versions, you can do a Pull Request on older branches
of this bundle, maybe it will be merged.
The same policy applies to old versions of PHP, out of active support: this bundle is actively
supporting PHP 7.2 and 7.3.
supporting PHP 7.3 and 8.0.

You can check if a given Symfony version is still supported by visiting [its
releases page](//symfony.com/releases).
Expand Down

0 comments on commit efc28ae

Please sign in to comment.