From ac4621df58eb4725aae61d9968312e7d0c8852b4 Mon Sep 17 00:00:00 2001 From: Lei Ni <7233663+leni-msft@users.noreply.github.com> Date: Thu, 3 Nov 2022 13:44:11 +0800 Subject: [PATCH] Update QuickStart.md (#21405) * Update QuickStart.md * Update QuickStart.md --- documentation/api-scenario/how-to/QuickStart.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/documentation/api-scenario/how-to/QuickStart.md b/documentation/api-scenario/how-to/QuickStart.md index dd1af850e5b1..ebfb32d6f267 100644 --- a/documentation/api-scenario/how-to/QuickStart.md +++ b/documentation/api-scenario/how-to/QuickStart.md @@ -24,7 +24,7 @@ npm install -g oav - Validation result report. After each run API scenario, developer will get a validation report which contains detected issue in API test. - Integrate everywhere. Easily integrate with azure-pipeline, cloud-test. -See `oav run -h` to find all available options. +Run `oav run -h` to find all available options. ## Create AAD app @@ -104,20 +104,22 @@ The `env.json` file contains required API scenario variables such as, subscripti ```json { - "subscriptionId": "", + "subscriptionId": "", "location": "westcentralus", "tenantId": "", - "client_id": "", - "client_secret": "" + "client_id": "", + "client_secret": "" } ``` #### 3. Run API Scenario test ```sh -oav run ~/workspace/azure-rest-api-specs/specification/appconfiguration/resource-manager/Microsoft.AppConfiguration/stable/2022-05-01/scenarios/quickstart.yaml --tag=package-2022-05-01 -e env.json --verbose +oav run ~/workspace/azure-rest-api-specs/specification/appconfiguration/resource-manager/Microsoft.AppConfiguration/stable/2022-05-01/scenarios/quickstart.yaml --tag package-2022-05-01 -e env.json --verbose ``` +The `--tag` parameter specifies tag name in the autorest configuration (readme.md) file, and Swagger files under the tag will be loaded. By default, oav tries to find the closest readme.md file in the upper directories of the scenario file, and use the "default" tag in it. You can use `--readme` and `--tag` to specify readme.md file and tag to load Swagger files, or `--specs` to specify Swagger files directly. + #### 4. Debug with Postman Sometimes the command `oav run` may fail due to non 2xx HTTP status code. Now you need to debug the API scenario with Postman.