ci: Add integration test runner scripts for GAPIC Showcase - #997
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces integration testing scripts (runintegrationtests.sh and startshowcase.sh) that download, run, and clean up the GAPIC Showcase server to test the Generator solution, alongside updates to .gitignore to ignore the generated showcase files. The review feedback highlights several critical improvements: resolving a compatibility issue on macOS where setsid is unavailable, fixing a bug where set -eo pipefail prevents the version fallback from executing if curl fails, avoiding the deletion of downloaded binaries during cleanup to preserve caching, and ensuring proper quoting of paths and variables to prevent word-splitting issues.
97db1cf to
6005e3c
Compare
6005e3c to
d2e963f
Compare
| echo "Setup GAPIC Showcase for standard integration tests" | ||
| ./startshowcase.sh --port :7469 | ||
|
|
||
| export SHOWCASE_ENDPOINT=http://localhost:7469 | ||
| dotnet test $DOTNET_TEST_ARGS Google.Api.Generator.IntegrationTests | ||
|
|
||
| echo "Setup GAPIC Showcase with TLS for PQC integration tests" | ||
| ./startshowcase.sh --port :7469 --tls | ||
|
|
||
| export SHOWCASE_ENDPOINT=https://localhost:7469 | ||
| dotnet test $DOTNET_TEST_ARGS Google.Api.Generator.IntegrationTests --filter "FullyQualifiedName~Pqc" |
There was a problem hiding this comment.
Everything should run now under TLS, that's closer to real life.
| echo "Setup GAPIC Showcase for standard integration tests" | |
| ./startshowcase.sh --port :7469 | |
| export SHOWCASE_ENDPOINT=http://localhost:7469 | |
| dotnet test $DOTNET_TEST_ARGS Google.Api.Generator.IntegrationTests | |
| echo "Setup GAPIC Showcase with TLS for PQC integration tests" | |
| ./startshowcase.sh --port :7469 --tls | |
| export SHOWCASE_ENDPOINT=https://localhost:7469 | |
| dotnet test $DOTNET_TEST_ARGS Google.Api.Generator.IntegrationTests --filter "FullyQualifiedName~Pqc" | |
| echo "Setup GAPIC Showcase" | |
| ./startshowcase.sh --port :7469 --tls | |
| export SHOWCASE_ENDPOINT=https://localhost:7469 | |
| dotnet test $DOTNET_TEST_ARGS Google.Api.Generator.IntegrationTests |
| /gapic-showcase | ||
| /gapic-showcase.exe | ||
| /showcase.pid | ||
| /showcase.log |
There was a problem hiding this comment.
Can't we clean up after ourselves instead?
| pkill -f "gapic-showcase run" 2>/dev/null || true | ||
| sleep 1 | ||
|
|
||
| if [ ! -f gapic-showcase ] && [ ! -f gapic-showcase.exe ]; then |
There was a problem hiding this comment.
We probably want to always run with the latest version?
b/522438834