Skip to content

Commit d96c271

Browse files
ci(java): restrict presubmit samples ITs to only snapshot (#285)
This PR was generated using Autosynth. 🌈 Synth log will be available here: https://source.cloud.google.com/results/invocations/5c79db05-fcb7-41b3-beec-7d1313602164/targets - [ ] To automatically regenerate this PR, check this box. Source-Link: googleapis/synthtool@27e0e91
1 parent c3db86b commit d96c271

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

.kokoro/build.sh

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,16 @@ integration)
6969
RETURN_CODE=$?
7070
;;
7171
samples)
72-
if [[ -f samples/pom.xml ]]
72+
SAMPLES_DIR=samples
73+
# only run ITs in snapshot/ on presubmit PRs. run ITs in all 3 samples/ subdirectories otherwise.
74+
if [[ ! -z ${KOKORO_GITHUB_PULL_REQUEST_NUMBER} ]]
7375
then
74-
pushd samples
76+
SAMPLES_DIR=samples/snapshot
77+
fi
78+
79+
if [[ -f ${SAMPLES_DIR}/pom.xml ]]
80+
then
81+
pushd {SAMPLES_DIR}
7582
mvn -B \
7683
-Penable-samples \
7784
-DtrimStackTrace=false \

synth.metadata

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"git": {
55
"name": ".",
66
"remote": "https://github.com/googleapis/java-logging.git",
7-
"sha": "870d7d72a8938472354008fc9ea11bc36b5789ad"
7+
"sha": "961fea4d0e3f5adbc63b14d134e15685144ce6a9"
88
}
99
},
1010
{
@@ -19,7 +19,7 @@
1919
"git": {
2020
"name": "synthtool",
2121
"remote": "https://github.com/googleapis/synthtool.git",
22-
"sha": "b65ef07d99946d23e900ef2cc490274a16edd336"
22+
"sha": "27e0e916cbfdb3d5ff6639b686cc04f78a0b0386"
2323
}
2424
}
2525
],

0 commit comments

Comments
 (0)