change phpunit version from 4.8.36 to 5.7.27

pull/20579/head
Hannah Shi 5 years ago committed by Hannah Shi
parent 308ba0c254
commit 2e1cfb75a8
  1. 2
      examples/php/README.md
  2. 15
      src/php/README.md
  3. 24
      src/php/docker/README.md
  4. 4
      src/php/docker/alpine/Dockerfile
  5. 4
      src/php/docker/grpc-ext/Dockerfile
  6. 4
      src/php/docker/grpc-src/Dockerfile
  7. 4
      src/php/docker/php-future/Dockerfile
  8. 4
      src/php/docker/php-src/Dockerfile
  9. 4
      src/php/docker/php-zts/Dockerfile
  10. 4
      src/php/docker/php5/Dockerfile
  11. 4
      templates/src/php/docker/download_phpunit.include
  12. 6
      templates/tools/dockerfile/php_deps.include
  13. 6
      tools/dockerfile/distribtest/php_jessie_x64/Dockerfile
  14. 5
      tools/dockerfile/grpc_artifact_linux_x64/Dockerfile
  15. 6
      tools/dockerfile/interoptest/grpc_interop_php/Dockerfile
  16. 6
      tools/dockerfile/test/php_jessie_x64/Dockerfile
  17. 5
      tools/gce/linux_kokoro_performance_worker_init.sh

@ -4,7 +4,7 @@ gRPC in 3 minutes (PHP)
PREREQUISITES
-------------
This requires `php` >=5.5, `phpize`, `pecl`, `phpunit`
This requires `php` >=5.5, `phpize`, `pecl`
INSTALL
-------

@ -21,17 +21,17 @@ gRPC PHP installation instructions for Google Cloud Platform is in
For PHP5:
```sh
$ sudo apt-get install php5 php5-dev php-pear phpunit
$ sudo apt-get install php5 php5-dev php-pear
```
For PHP7:
```sh
$ sudo apt-get install php7.0 php7.0-dev php-pear phpunit
$ sudo apt-get install php7.0 php7.0-dev php-pear
```
or
```sh
$ sudo apt-get install php php-dev php-pear phpunit
$ sudo apt-get install php php-dev php-pear
```
**Install PHP and PECL on CentOS/RHEL 7:**
@ -54,10 +54,13 @@ $ sudo mv composer.phar /usr/local/bin/composer
```
**Install PHPUnit (Linux or Mac):**
PHP tests currently require using an older version of PHPUnit
```sh
$ wget https://phar.phpunit.de/phpunit-old.phar
$ chmod +x phpunit-old.phar
$ sudo mv phpunit-old.phar /usr/bin/phpunit
$ wget https://phar.phpunit.de/phpunit-5.7.27.phar
$ chmod +x phpunit-5.7.27.phar
$ sudo mv phpunit-5.7.27.phar /usr/local/bin/phpunit
```
## Install the gRPC PHP extension

@ -7,31 +7,37 @@ different PHP environments.
## Build and Run Tests
```sh
$ cd grpc
```
To build all docker images:
```sh
# cd grpc
$ ./src/php/bin/build_all_docker_images.sh
```
# or to only build some selected images
Or to only build some selected images
```sh
$ ./src/php/bin/build_all_docker_images.sh grpc-ext php-src
```
# or to only print out individual `docker build` commands
Or to only print out individual `docker build` commands
```sh
$ ./src/php/bin/build_all_docker_images.sh --cmds
```
To run all tests:
```sh
$ cd grpc
$ ./src/php/bin/run_all_docker_images.sh
```
# or to only run some selected images
Or to only run some selected images
```sh
$ ./src/php/bin/run_all_docker_images.sh grpc-ext php-src
```
# or to only print out individual `docker run` commands
Or to only print out individual `docker run` commands
```sh
$ ./src/php/bin/run_all_docker_images.sh --cmds
```

@ -19,8 +19,8 @@ RUN apk add autoconf g++ make zlib-dev git bash wget
WORKDIR /tmp
RUN wget https://phar.phpunit.de/phpunit-4.8.36.phar && \
mv phpunit-4.8.36.phar /usr/local/bin/phpunit && \
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit

@ -21,8 +21,8 @@ RUN apt-get -qq update && apt-get -qq install -y \
WORKDIR /tmp
RUN wget https://phar.phpunit.de/phpunit-4.8.36.phar && \
mv phpunit-4.8.36.phar /usr/local/bin/phpunit && \
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit

@ -21,8 +21,8 @@ RUN apt-get -qq update && apt-get -qq install -y \
WORKDIR /tmp
RUN wget https://phar.phpunit.de/phpunit-4.8.36.phar && \
mv phpunit-4.8.36.phar /usr/local/bin/phpunit && \
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit

@ -21,8 +21,8 @@ RUN apt-get -qq update && apt-get -qq install -y \
WORKDIR /tmp
RUN wget https://phar.phpunit.de/phpunit-4.8.36.phar && \
mv phpunit-4.8.36.phar /usr/local/bin/phpunit && \
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit

@ -23,8 +23,8 @@ RUN apt-get -qq update && apt-get -qq install -y \
WORKDIR /tmp
RUN wget https://phar.phpunit.de/phpunit-4.8.36.phar && \
mv phpunit-4.8.36.phar /usr/local/bin/phpunit && \
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit

@ -21,8 +21,8 @@ RUN apt-get -qq update && apt-get -qq install -y \
WORKDIR /tmp
RUN wget https://phar.phpunit.de/phpunit-4.8.36.phar && \
mv phpunit-4.8.36.phar /usr/local/bin/phpunit && \
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit

@ -21,8 +21,8 @@ RUN apt-get -qq update && apt-get -qq install -y \
WORKDIR /tmp
RUN wget https://phar.phpunit.de/phpunit-4.8.36.phar && \
mv phpunit-4.8.36.phar /usr/local/bin/phpunit && \
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit

@ -1,3 +1,3 @@
RUN wget https://phar.phpunit.de/phpunit-4.8.36.phar && ${'\\'}
mv phpunit-4.8.36.phar /usr/local/bin/phpunit && ${'\\'}
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && ${'\\'}
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && ${'\\'}
chmod +x /usr/local/bin/phpunit

@ -4,4 +4,8 @@
# Install dependencies
RUN apt-get update && apt-get install -y ${'\\'}
git php5 php5-dev phpunit unzip
git php5 php5-dev unzip
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && ${'\\'}
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && ${'\\'}
chmod +x /usr/local/bin/phpunit

@ -14,4 +14,8 @@
FROM debian:jessie
RUN apt-get update && apt-get install -y php5 php5-dev php-pear phpunit
RUN apt-get update && apt-get install -y php5 php5-dev php-pear
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit

@ -67,8 +67,11 @@ RUN /bin/bash -l -c "gem install bundler -v 1.17.3 --no-document"
# PHP dependencies
RUN apt-get update && apt-get install -y \
php5 php5-dev php-pear phpunit && apt-get clean
php5 php5-dev php-pear && apt-get clean
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit
##################
# C# dependencies (needed to build grpc_csharp_ext)

@ -56,7 +56,11 @@ RUN apt-get update && apt-get install -y time && apt-get clean
# Install dependencies
RUN apt-get update && apt-get install -y \
git php5 php5-dev phpunit unzip
git php5 php5-dev unzip
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit
RUN mkdir /var/local/jenkins

@ -75,7 +75,11 @@ RUN pip install futures==2.2.0 enum34==1.0.4 protobuf==3.5.2.post1 six==1.10.0 t
# Install dependencies
RUN apt-get update && apt-get install -y \
git php5 php5-dev phpunit unzip
git php5 php5-dev unzip
RUN wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
chmod +x /usr/local/bin/phpunit
RUN mkdir /var/local/jenkins

@ -161,7 +161,10 @@ ruby -v
gem install bundler
# PHP dependencies
sudo apt-get install -y php php-dev phpunit php-pear unzip zlib1g-dev
sudo apt-get install -y php php-dev php-pear unzip zlib1g-dev
sudo wget https://phar.phpunit.de/phpunit-5.7.27.phar && \
sudo mv phpunit-5.7.27.phar /usr/local/bin/phpunit && \
sudo chmod +x /usr/local/bin/phpunit
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer

Loading…
Cancel
Save