[e3d4e0a] | 1 | <?php
|
---|
| 2 | /*
|
---|
| 3 | * Copyright 2014 Google Inc.
|
---|
| 4 | *
|
---|
| 5 | * Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
---|
| 6 | * use this file except in compliance with the License. You may obtain a copy of
|
---|
| 7 | * the License at
|
---|
| 8 | *
|
---|
| 9 | * http://www.apache.org/licenses/LICENSE-2.0
|
---|
| 10 | *
|
---|
| 11 | * Unless required by applicable law or agreed to in writing, software
|
---|
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
---|
| 13 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
---|
| 14 | * License for the specific language governing permissions and limitations under
|
---|
| 15 | * the License.
|
---|
| 16 | */
|
---|
| 17 |
|
---|
| 18 | namespace Google\Service\ToolResults\Resource;
|
---|
| 19 |
|
---|
| 20 | use Google\Service\ToolResults\ListTestCasesResponse;
|
---|
| 21 | use Google\Service\ToolResults\TestCase;
|
---|
| 22 |
|
---|
| 23 | /**
|
---|
| 24 | * The "testCases" collection of methods.
|
---|
| 25 | * Typical usage is:
|
---|
| 26 | * <code>
|
---|
| 27 | * $toolresultsService = new Google\Service\ToolResults(...);
|
---|
| 28 | * $testCases = $toolresultsService->projects_histories_executions_steps_testCases;
|
---|
| 29 | * </code>
|
---|
| 30 | */
|
---|
| 31 | class ProjectsHistoriesExecutionsStepsTestCases extends \Google\Service\Resource
|
---|
| 32 | {
|
---|
| 33 | /**
|
---|
| 34 | * Gets details of a Test Case for a Step. Experimental test cases API. Still in
|
---|
| 35 | * active development. May return any of the following canonical error codes: -
|
---|
| 36 | * PERMISSION_DENIED - if the user is not authorized to write to project -
|
---|
| 37 | * INVALID_ARGUMENT - if the request is malformed - NOT_FOUND - if the
|
---|
| 38 | * containing Test Case does not exist (testCases.get)
|
---|
| 39 | *
|
---|
| 40 | * @param string $projectId A Project id. Required.
|
---|
| 41 | * @param string $historyId A History id. Required.
|
---|
| 42 | * @param string $executionId A Execution id Required.
|
---|
| 43 | * @param string $stepId A Step id. Note: This step must include a
|
---|
| 44 | * TestExecutionStep. Required.
|
---|
| 45 | * @param string $testCaseId A Test Case id. Required.
|
---|
| 46 | * @param array $optParams Optional parameters.
|
---|
| 47 | * @return TestCase
|
---|
| 48 | * @throws \Google\Service\Exception
|
---|
| 49 | */
|
---|
| 50 | public function get($projectId, $historyId, $executionId, $stepId, $testCaseId, $optParams = [])
|
---|
| 51 | {
|
---|
| 52 | $params = ['projectId' => $projectId, 'historyId' => $historyId, 'executionId' => $executionId, 'stepId' => $stepId, 'testCaseId' => $testCaseId];
|
---|
| 53 | $params = array_merge($params, $optParams);
|
---|
| 54 | return $this->call('get', [$params], TestCase::class);
|
---|
| 55 | }
|
---|
| 56 | /**
|
---|
| 57 | * Lists Test Cases attached to a Step. Experimental test cases API. Still in
|
---|
| 58 | * active development. May return any of the following canonical error codes: -
|
---|
| 59 | * PERMISSION_DENIED - if the user is not authorized to write to project -
|
---|
| 60 | * INVALID_ARGUMENT - if the request is malformed - NOT_FOUND - if the
|
---|
| 61 | * containing Step does not exist
|
---|
| 62 | * (testCases.listProjectsHistoriesExecutionsStepsTestCases)
|
---|
| 63 | *
|
---|
| 64 | * @param string $projectId A Project id. Required.
|
---|
| 65 | * @param string $historyId A History id. Required.
|
---|
| 66 | * @param string $executionId A Execution id Required.
|
---|
| 67 | * @param string $stepId A Step id. Note: This step must include a
|
---|
| 68 | * TestExecutionStep. Required.
|
---|
| 69 | * @param array $optParams Optional parameters.
|
---|
| 70 | *
|
---|
| 71 | * @opt_param int pageSize The maximum number of TestCases to fetch. Default
|
---|
| 72 | * value: 100. The server will use this default if the field is not set or has a
|
---|
| 73 | * value of 0. Optional.
|
---|
| 74 | * @opt_param string pageToken A continuation token to resume the query at the
|
---|
| 75 | * next item. Optional.
|
---|
| 76 | * @return ListTestCasesResponse
|
---|
| 77 | * @throws \Google\Service\Exception
|
---|
| 78 | */
|
---|
| 79 | public function listProjectsHistoriesExecutionsStepsTestCases($projectId, $historyId, $executionId, $stepId, $optParams = [])
|
---|
| 80 | {
|
---|
| 81 | $params = ['projectId' => $projectId, 'historyId' => $historyId, 'executionId' => $executionId, 'stepId' => $stepId];
|
---|
| 82 | $params = array_merge($params, $optParams);
|
---|
| 83 | return $this->call('list', [$params], ListTestCasesResponse::class);
|
---|
| 84 | }
|
---|
| 85 | }
|
---|
| 86 |
|
---|
| 87 | // Adding a class alias for backwards compatibility with the previous class name.
|
---|
| 88 | class_alias(ProjectsHistoriesExecutionsStepsTestCases::class, 'Google_Service_ToolResults_Resource_ProjectsHistoriesExecutionsStepsTestCases');
|
---|