

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 識別共用報告群組
<a name="report-groups-sharing-identify"></a>

擁有者和取用者可以使用 AWS CLI 來識別共用報告群組。

若要識別並取得共用報告群組及其報告的資訊，請使用下列命令：
+  若要查看與您共用的報告群組 ARN，請執行 `[list-shared-report-groups](https://docs.aws.amazon.com/cli/latest/reference/codebuild/list-shared-report-groups.html)`：

  ```
  aws codebuild list-shared-report-groups
  ```
+  若要查看在報告存取中的報告 ARN，請使用報告群組 ARN 執行 `[list-reports-for-report-group](https://docs.aws.amazon.com/cli/latest/reference/codebuild/list-reports-for-report-group.html)`：

  ```
  aws codebuild list-reports-for-report-group --report-group-arn report-group-arn
  ```
+  若要查看報告中測試案例的相關資訊，請使用報告 ARN 執行 `[describe-test-cases](https://docs.aws.amazon.com/cli/latest/reference/codebuild/describe-test-cases.html)`：

  ```
  aws codebuild describe-test-cases --report-arn report-arn
  ```

   輸出看起來如下：

  ```
  {
      "testCases": [
          {
              "status": "FAILED",
              "name": "Test case 1",
              "expired": 1575916770.0,
              "reportArn": "report-arn",
              "prefix": "Cucumber tests for agent",
              "message": "A test message",
              "durationInNanoSeconds": 1540540,
              "testRawDataPath": "path-to-output-report-files"
          },
          {
              "status": "SUCCEEDED",
              "name": "Test case 2",
              "expired": 1575916770.0,
              "reportArn": "report-arn",
              "prefix": "Cucumber tests for agent",
              "message": "A test message",
              "durationInNanoSeconds": 1540540,
              "testRawDataPath": "path-to-output-report-files"
          }
      ]
  }
  ```