Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing tweaks #581

Merged
merged 1 commit into from
Mar 24, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 5 additions & 7 deletions circle.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,15 @@
machine:
java:
version: oraclejdk8
environment:
chromedriver_path: /usr/local/bin/chromedriver
dependencies:
pre:
- sudo mkdir /opt/webdriver/
- curl -LO https://github.com/mozilla/geckodriver/releases/download/v0.15.0/geckodriver-v0.15.0-linux64.tar.gz
&& sudo tar -zxf geckodriver-*.tar.gz -C /opt/webdriver/
&& sudo tar -zxf geckodriver-*.tar.gz -C "${HOME}/bin"
- sudo apt-add-repository "deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe"
- sudo apt-get update
- sudo apt-get install -t trusty-backports shellcheck
&& sudo apt-get update
&& sudo apt-get install -t trusty-backports shellcheck
- sudo apt-get install expect
test:
override:
- bash ./travis.sh
- bash ./travis.sh &&
bash <(curl -s https://codecov.io/bash) # If successful, run code coverage
16 changes: 9 additions & 7 deletions travis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,19 @@
# limitations under the License.

set -e
set -x
# Set pipefail so that `egrep` does not eat the exit code.
set -o pipefail
shopt -s globstar


# Setup GCP application default credentials
# Setup GCP application default credentials before `set -x` echos everything out
if [[ $GCLOUD_SERVICE_KEY ]]; then
echo "$GCLOUD_SERVICE_KEY" | \
base64 --decode --ignore-garbage > "${HOME}/google-cloud-service-key.json"
export GOOGLE_APPLICATION_CREDENTIALS="${HOME}/google-cloud-service-key.json"
fi

set -x
# Set pipefail so that `egrep` does not eat the exit code.
set -o pipefail
shopt -s globstar


SKIP_TESTS=false
if [ -z "$GOOGLE_APPLICATION_CREDENTIALS" ] ; then
Expand Down Expand Up @@ -76,7 +76,9 @@ common_travis_dir="$(travis_changed_files_parent)"

# Give Maven a bit more memory
export MAVEN_OPTS='-XX:+PrintFlagsFinal -Xmx800m -Xms400m'
"${TRAVIS_BUILD_DIR-$HOME/$CIRCLE_PROJECT_REPONAME}"/mvnw --batch-mode clean verify -e -DskipTests=$SKIP_TESTS | \
"${TRAVIS_BUILD_DIR-$HOME/$CIRCLE_PROJECT_REPONAME}"/mvnw \
--batch-mode clean verify -e \
-DskipTests=$SKIP_TESTS \
egrep -v "(^\[INFO\] Download|^\[INFO\].*skipping)"

[ -z "$common_travis_dir" ] || popd
Expand Down