This change publishes a build scan to ge.spring.io for every local build from an authenticated Spring committer and for CI where appropriate access tokens are available. The build will not fail if publishing fails. This change also allows the build to benefit from local and remote build caching, providing faster builds for all contributors. Additionally, the project will have access to all features of Gradle Enterprise such as: - Dashboards to view all historical build scans, along with performance trends over time - Build failure analytics for enhanced investigation and diagnosis of build failures - Test failure analytics to better understand trends and causes around slow, failing, and flaky tests See #2732
30 lines
832 B
Bash
Executable File
30 lines
832 B
Bash
Executable File
#!/bin/bash -x
|
|
|
|
set -euo pipefail
|
|
|
|
rm -f work
|
|
|
|
# Create link to directory with Redis binaries
|
|
cwd=$(pwd)
|
|
|
|
# Launch Redis in proper configuration
|
|
pushd /tmp && ln -s /work && make -f $cwd/Makefile start && popd
|
|
|
|
export DEVELOCITY_CACHE_USERNAME=${DEVELOCITY_CACHE_USR}
|
|
export DEVELOCITY_CACHE_PASSWORD=${DEVELOCITY_CACHE_PSW}
|
|
|
|
# The environment variable to configure access key is still GRADLE_ENTERPRISE_ACCESS_KEY
|
|
export GRADLE_ENTERPRISE_ACCESS_KEY=${DEVELOCITY_ACCESS_KEY}
|
|
|
|
# Execute maven test
|
|
MAVEN_OPTS="-Duser.name=spring-builds+jenkins -Duser.home=/tmp/jenkins-home" ./mvnw -s settings.xml clean test -P${PROFILE} -DrunLongTests=${LONG_TESTS:-false} -U -B
|
|
|
|
# Capture resulting exit code from maven (pass/fail)
|
|
RESULT=$?
|
|
|
|
# Shutdown Redis
|
|
pushd /tmp && make -f $cwd/Makefile stop && popd
|
|
|
|
# Return maven results
|
|
exit $RESULT
|