-
Notifications
You must be signed in to change notification settings - Fork 463
feat: [Gax] Add script to download and generate the showcase client and download the showcase server #9347
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
feat: [Gax] Add script to download and generate the showcase client and download the showcase server #9347
Changes from all commits
787b430
75c704e
f5c0273
0101af0
f8cdd9a
20aed66
efe4ac3
3583cb9
b34aa29
76eb66e
6720263
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| # GAX Showcase Conformance Testing | ||
|
|
||
| This directory contains the integration conformance test suite (`ShowcaseTest.php`) and generated client SDK for `gapic-showcase`. | ||
|
|
||
| ## Prerequisites | ||
|
|
||
| - **Protobuf Compiler (`protoc`)**: Ensure `protoc` is installed and available in your `$PATH`. | ||
| - **Dev Dependencies**: Ensure dev dependencies are installed: | ||
| ```sh | ||
| composer install -d dev/ | ||
| ``` | ||
|
|
||
| ## Generating the Showcase Client | ||
|
|
||
| To generate or update the Showcase client SDK, message classes, and metadata using the PHP CLI tool: | ||
|
|
||
| ```sh | ||
| # From the repository root, run the console command: | ||
| ./dev/google-cloud showcase:generate | ||
| ``` | ||
|
|
||
| Options: | ||
| - `-o, --out-dir <dir>`: Output directory relative to repository root (defaults to `Gax`). | ||
| - `-p, --showcase-path <dir>`: Path to local `gapic-showcase` repository (defaults to installed vendor dependency). | ||
| - `-g, --generator-path <dir>`: Path to local `gapic-generator-php` (defaults to installed vendor dependency). | ||
| - `-a, --googleapis-path <dir>`: Path to `googleapis` repository (defaults to submodule in `gapic-generator-php`). | ||
|
|
||
| ## Running Conformance Tests | ||
|
|
||
| 1. Install and launch the matching `gapic-showcase` mock server in the background: | ||
| ```sh | ||
| # Option 1 (curl) | ||
| curl -L https://github.com/googleapis/gapic-showcase/releases/download/v0.41.1/gapic-showcase-0.41.1-linux-amd64.tar.gz | tar -zx | ||
| ./gapic-showcase run & | ||
|
|
||
| # Option 2 (go install) | ||
| go install github.com/googleapis/gapic-showcase/cmd/gapic-showcase@latest | ||
| gapic-showcase run & | ||
| ``` | ||
|
|
||
| 2. Run the PHPUnit conformance test suite: | ||
| ```sh | ||
| vendor/bin/phpunit -c Gax/phpunit-conformance.xml.dist | ||
| # or from the Gax directory: | ||
| cd Gax && vendor/bin/phpunit tests/Conformance/ShowcaseTest.php | ||
| ``` | ||
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Uh oh!
There was an error while loading. Please reload this page.