Skip to content

Commit

Permalink
HSEARCH-2434 Add an Elasticsearch 5 build to the travis build
Browse files Browse the repository at this point in the history
  • Loading branch information
yrodiere committed Mar 21, 2017
1 parent a0b0aeb commit ca85bd7
Showing 1 changed file with 20 additions and 6 deletions.
26 changes: 20 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,10 @@ cache:
directories:
- $HOME/.m2
env:
- DB=h2
# for now, only test with the most recent version of ES for each major
#- DB=h2 ELASTICSEARCH=2.0
- DB=h2 ELASTICSEARCH=2.2
- DB=h2 ELASTICSEARCH=5.0
# for now, let's test only with H2
#- DB=pgsql
#- DB=mariadb
Expand All @@ -33,9 +36,20 @@ install:
# we run checkstyle first to fail fast if there is a styling error
- ./mvnw -s settings-example.xml checkstyle:check
before_script:
- if [[ "$DB" == "pgsql" ]]; then psql -U postgres -f 'travis/pgsql.sql';fi
- if [[ "$DB" == "mariadb" ]]; then mysql -u root < 'travis/mariadb.sql'; fi
- case $DB in
"h2") ;;
"pgsql") psql -U postgres -f 'travis/pgsql.sql' ;;
"mariadb") mysql -u root < 'travis/mariadb.sql' ;;
esac
script:
- if [[ "$DB" == "h2" ]]; then ./mvnw -s settings-example.xml -Pdocs,dist clean install;fi
- if [[ "$DB" == "pgsql" ]]; then ./mvnw -s settings-example.xml -Pci-postgresql,docs,dist clean install;fi
- if [[ "$DB" == "mariadb" ]]; then ./mvnw -s settings-example.xml -Pci-mariadb,docs,dist clean install; fi
- case $DB in
"h2") ;;
"pgsql") BUILD_OPTIONS+=' -Pci-postgresql' ;;
"mariadb") BUILD_OPTIONS+=' -Pci-mariadb' ;;
esac
- case $ELASTICSEARCH in
2.0) BUILD_OPTIONS+=' -P!elasticsearch-2.2,elasticsearch-2.0' ;;
2.2) ;;
5.0) BUILD_OPTIONS+=' -P!elasticsearch-2.2,elasticsearch-5.0' ;;
esac
- ./mvnw -s settings-example.xml -Pdocs,dist $BUILD_OPTIONS clean install

0 comments on commit ca85bd7

Please sign in to comment.