From 5d9f62a49a59fa4103e5eadd1729c722d5ad7784 Mon Sep 17 00:00:00 2001 From: Donna Dionne Date: Tue, 24 Feb 2015 19:15:51 -0800 Subject: [PATCH] Adding auth test into suite to be run automatically Temporarly taking out time out as it is not working properly on gcloud command Restore a flag incorrectly removed earlier --- tools/gce_setup/cloud_prod_runner.sh | 13 +++++++++++++ tools/gce_setup/grpc_docker.sh | 26 ++++---------------------- 2 files changed, 17 insertions(+), 22 deletions(-) diff --git a/tools/gce_setup/cloud_prod_runner.sh b/tools/gce_setup/cloud_prod_runner.sh index 52e9b5e2a32..4732f952c26 100755 --- a/tools/gce_setup/cloud_prod_runner.sh +++ b/tools/gce_setup/cloud_prod_runner.sh @@ -32,6 +32,7 @@ main() { source grpc_docker.sh test_cases=(large_unary empty_unary ping_pong client_streaming server_streaming service_account_creds compute_engine_creds) + auth_test_cases=(service_account_creds compute_engine_creds) clients=(cxx java go ruby node) for test_case in "${test_cases[@]}" do @@ -45,6 +46,18 @@ main() { fi done done + for test_case in "${auth_test_cases[@]}" + do + for client in "${clients[@]}" + do + if grpc_cloud_prod_auth_test $test_case grpc-docker-testclients $client + then + echo "$test_case $client $server passed" >> /tmp/cloud_prod_result.txt + else + echo "$test_case $client $server failed" >> /tmp/cloud_prod_result.txt + fi + done + done gsutil cp /tmp/cloud_prod_result.txt gs://stoked-keyword-656-output/cloud_prod_result.txt rm /tmp/cloud_prod_result.txt } diff --git a/tools/gce_setup/grpc_docker.sh b/tools/gce_setup/grpc_docker.sh index 6fff057c832..231625efb3a 100755 --- a/tools/gce_setup/grpc_docker.sh +++ b/tools/gce_setup/grpc_docker.sh @@ -350,7 +350,7 @@ grpc_interop_test_flags() { echo "$FUNCNAME: missing arg: test_case" 1>&2 return 1 } - echo "--server_host=$server_ip --server_port=$port --test_case=$test_case" + echo "--server_host_override=foo.test.google.fr --server_host=$server_ip --server_port=$port --test_case=$test_case" } # checks the positional args and assigns them to variables visible in the caller @@ -673,7 +673,7 @@ _grpc_launch_servers_args() { [[ -n $1 ]] && { servers="$@" } || { - servers="cxx java go node ruby" + servers="cxx java go node ruby python" echo "$FUNCNAME: no servers specified, will launch defaults '$servers'" } } @@ -795,16 +795,7 @@ grpc_interop_test() { echo " $ssh_cmd" echo "on $host" [[ $dry_run == 1 ]] && return 0 # don't run the command on a dry run - gcloud compute $project_opt ssh $zone_opt $host --command "$cmd" & - PID=$! - sleep 10 - echo "pid is $PID" - if ps -p $PID - then - kill $PID - return 1 - fi - + gcloud compute $project_opt ssh $zone_opt $host --command "$cmd" } # Runs a test command on a docker instance. @@ -850,16 +841,7 @@ grpc_cloud_prod_test() { echo " $ssh_cmd" echo "on $host" [[ $dry_run == 1 ]] && return 0 # don't run the command on a dry run - gcloud compute $project_opt ssh $zone_opt $host --command "$cmd" & - PID=$! - sleep 10 - echo "pid is $PID" - if ps -p $PID - then - kill $PID - return 1 - fi - + gcloud compute $project_opt ssh $zone_opt $host --command "$cmd" } # Runs a test command on a docker instance.