enable php interop tests

pull/3373/head
Jan Tattermusch 9 years ago
parent f49936acef
commit f88f3e2c69
  1. 24
      tools/jenkins/docker_run_interop_tests.sh
  2. 19
      tools/run_tests/run_interop_tests.py

@ -62,21 +62,21 @@ make install_c -C /var/local/git/grpc
# TODO(jtattermusch): add python
# build PHP interop client
# TODO(jtattermusch): make php work
# TODO(jtattermusch): prerequisites should be installed sooner than here.
# TODO(jtattermusch): prerequisites for PHP should be installed sooner than here.
# Install composer
#curl -sS https://getcomposer.org/installer | php
#mv composer.phar /usr/local/bin/composer
curl -sS https://getcomposer.org/installer | php
mv composer.phar /usr/local/bin/composer
# Download the patched PHP protobuf so that PHP gRPC clients can be generated
# from proto3 schemas.
#git clone https://github.com/stanley-cheung/Protobuf-PHP.git /var/local/git/protobuf-php
#(cd src/php/ext/grpc && phpize && ./configure && make)
#rvm all do gem install ronn rake
#(cd /var/local/git/protobuf-php \
# && rvm all do rake pear:package version=1.0 \
# && pear install Protobuf-1.0.tgz)
#(cd src/php && composer install)
#(cd src/php && protoc-gen-php -i tests/interop/ -o tests/interop/ tests/interop/test.proto)
git clone https://github.com/stanley-cheung/Protobuf-PHP.git /var/local/git/protobuf-php
(cd src/php/ext/grpc && phpize && ./configure && make)
rvm all do gem install ronn rake
(cd third_party/protobuf && make install)
(cd /var/local/git/protobuf-php \
&& rvm all do rake pear:package version=1.0 \
&& pear install Protobuf-1.0.tgz)
(cd src/php && composer install)
(cd src/php && protoc-gen-php -i tests/interop/ -o tests/interop/ tests/interop/test.proto)
# run the cloud-to-prod interop tests
tools/run_tests/run_interop_tests.py -l $language

@ -98,6 +98,24 @@ class NodeLanguage:
def __str__(self):
return 'node'
class PHPLanguage:
def __init__(self):
self.client_cmdline_base = ['src/php/bin/interop_client.sh']
self.client_cwd = None
def cloud_to_prod_args(self):
return (self.client_cmdline_base + _CLOUD_TO_PROD_BASE_ARGS +
['--use_tls'])
def cloud_to_prod_env(self):
return _SSL_CERT_ENV
def __str__(self):
return 'php'
class RubyLanguage:
def __init__(self):
@ -120,6 +138,7 @@ _LANGUAGES = {
'c++' : CXXLanguage(),
'csharp' : CSharpLanguage(),
'node' : NodeLanguage(),
'php' : PHPLanguage(),
'ruby' : RubyLanguage(),
}

Loading…
Cancel
Save