From 21959886759e7d1a752ce167414fa2ae571b0828 Mon Sep 17 00:00:00 2001 From: Xavier Rousset Date: Wed, 21 Feb 2018 18:35:45 +0100 Subject: [PATCH] PHRAS-1884 Bump php to 7.0.24 on circle CI and elastic to 2.3.3. --- circle.yml | 19 ++++++++++++------- .../SearchEngine/SearchEngineOptions.php | 4 ++-- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/circle.yml b/circle.yml index 4cd0d33408..8ebc45b129 100644 --- a/circle.yml +++ b/circle.yml @@ -7,7 +7,7 @@ general: machine: php: - version: 5.5.31 + version: 7.0.24 #5.6.22 node: version: stable services: @@ -18,16 +18,16 @@ machine: dependencies: cache_directories: - - elasticsearch-1.6.0 # relative to the build directory + - elasticsearch-2.3.3 # relative to the build directory - node_modules - ~/.composer pre: - git clone https://github.com/alanxz/rabbitmq-c - cd rabbitmq-c && git checkout 2ca1774489328cde71195f5fa95e17cf3a80cb8a - cd rabbitmq-c && git submodule init && git submodule update && autoreconf -i && ./configure && make && sudo make install - - pecl install amqp-1.6.0 + - pecl channel-update pear.php.net + - yes '' | pecl install amqp-1.9.3 - yes '' | pecl install imagick - - pecl install json - sudo apt-get install libzmq-dev - yes '' | pecl install zmq-beta - echo "extension = amqp.so" > /opt/circleci/php/$(phpenv global)/etc/conf.d/amqp.ini @@ -39,8 +39,8 @@ dependencies: - composer install --no-progress --no-interaction --optimize-autoloader post: - npm install - - if [[ ! -e elasticsearch-1.6.0 ]]; then wget --no-check-certificate https://download.elastic.co/elasticsearch/elasticsearch/elasticsearch-1.6.0.tar.gz && tar -xvf elasticsearch-1.6.0.tar.gz && elasticsearch-1.6.0/bin/plugin install elasticsearch/elasticsearch-analysis-icu/2.6.0; fi - - elasticsearch-1.6.0/bin/elasticsearch: {background: true} + - if [[ ! -e elasticsearch-2.3.3 ]]; then wget --no-check-certificate https://download.elastic.co/elasticsearch/elasticsearch/elasticsearch-2.3.3.tar.gz && tar -xvf elasticsearch-2.3.3.tar.gz && elasticsearch-2.3.3/bin/plugin install analysis-icu; fi + - elasticsearch-2.3.3/bin/elasticsearch: {background: true} database: override: @@ -53,7 +53,12 @@ database: - "./bin/developer phraseanet:regenerate-sqlite -v" - "./bin/developer phraseanet:generate-js-fixtures -v" +#test: +# override: +# - case $CIRCLE_NODE_INDEX in 0) EXIT=0; php -d memory_limit=-1 bin/phpunit --log-junit $CIRCLE_TEST_REPORTS/phpunit/junit-unit.xml --exclude-group legacy || EXIT=$?; php -d memory_limit=-1 bin/phpunit --log-junit $CIRCLE_TEST_REPORTS/phpunit/junit-legacy-no-web.xml --group legacy --exclude-group web || EXIT=$?; exit $EXIT;; 1) php -d memory_limit=-1 bin/phpunit --log-junit $CIRCLE_TEST_REPORTS/phpunit/junit-legacy-web.xml --group web ;; esac: +# #- php -d memory_limit=-1 bin/phpunit -c phpunit.xml.dist; + test: override: - case $CIRCLE_NODE_INDEX in 0) EXIT=0; php -d memory_limit=-1 bin/phpunit --log-junit $CIRCLE_TEST_REPORTS/phpunit/junit-unit.xml --exclude-group legacy || EXIT=$?; php -d memory_limit=-1 bin/phpunit --log-junit $CIRCLE_TEST_REPORTS/phpunit/junit-legacy-no-web.xml --group legacy --exclude-group web || EXIT=$?; exit $EXIT;; 1) php -d memory_limit=-1 bin/phpunit --log-junit $CIRCLE_TEST_REPORTS/phpunit/junit-legacy-web.xml --group web ;; esac: - parallel: true + parallel: true \ No newline at end of file diff --git a/lib/Alchemy/Phrasea/SearchEngine/SearchEngineOptions.php b/lib/Alchemy/Phrasea/SearchEngine/SearchEngineOptions.php index ad704575d9..3c98683c46 100644 --- a/lib/Alchemy/Phrasea/SearchEngine/SearchEngineOptions.php +++ b/lib/Alchemy/Phrasea/SearchEngine/SearchEngineOptions.php @@ -261,10 +261,10 @@ class SearchEngineOptions /** * Set the bases where to search for * - * @param int[] $basesIds An array of ids + * @param null|int[] $basesIds An array of ids * @return $this */ - public function onBasesIds(array $basesIds) + public function onBasesIds($basesIds) { $this->basesIds = $basesIds;