Skip to content
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: 12 additions & 0 deletions .kokoro/lint.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Format: //devtools/kokoro/config/proto/build.proto

# Configure the docker image for kokoro-trampoline.
env_vars: {
key: "TRAMPOLINE_IMAGE"
value: "gcr.io/cloud-devrel-kokoro-resources/php74"
}

env_vars: {
key: "RUN_CS_CHECK"
value: "true"
}
33 changes: 33 additions & 0 deletions .kokoro/lint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/bin/bash

# Copyright 2021 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

set -e

if [ "${BASH_DEBUG}" = "true" ]; then
set -x
fi

# Kokoro directory for running these samples
cd github/php-docs-samples

mkdir -p build/logs

export PULL_REQUEST_NUMBER=$KOKORO_GITHUB_PULL_REQUEST_NUMBER

# Run code standards check when appropriate
if [ "${RUN_CS_CHECK}" = "true" ]; then
bash testing/run_cs_check.sh
fi
8 changes: 7 additions & 1 deletion .kokoro/system_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,11 @@ fi
# Install global test dependencies
composer install -d testing/

# cd into specific subdirectory (if appropriate)
MAIN_DIR=$(pwd)
if [ ! -z "${SUB_DIRECTORY}" ]; then
cd $SUB_DIRECTORY
fi

# Run tests
bash testing/run_test_suite.sh
bash $MAIN_DIR/testing/run_test_suite.sh