Skip to content

Commit

Permalink
chore(ci): break out of loop when not in a dir/example
Browse files Browse the repository at this point in the history
  • Loading branch information
YOU54F committed Nov 10, 2023
1 parent 3de2bdc commit c0286db
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions scripts/ci/test-examples.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")"; pwd)" # Figure out where the

echo "Running e2e examples build for node version $(node --version)"
for i in examples/*; do
[ -d "$i" ] || continue # prevent failure if not a directory
[ -e "$i" ] || continue # prevent failure if there are no examples
[ -d "$i" ] || break # prevent failure if not a directory
[ -e "$i" ] || break # prevent failure if there are no examples
echo "--> running tests for: $i"
pushd "$i"
# replace pact dependency with locally build version
Expand Down Expand Up @@ -42,8 +42,8 @@ echo "Running Vx examples build"
# trap "docker kill $BROKER_ID" EXIT

for i in examples/v*/*; do
[ -d "$i" ] || continue # prevent failure if not a directory
[ -e "$i" ] || continue # prevent failure if there are no examples
[ -d "$i" ] || break # prevent failure if not a directory
[ -e "$i" ] || break # prevent failure if there are no examples
echo "------------------------------------------------"
echo "------------> continuing to test V3/v$ example project: $i"
node --version
Expand Down

0 comments on commit c0286db

Please sign in to comment.