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 18namespace Google\Service; 19 20use Google\Client; 21 22/** 23 * Service definition for Testing (v1). 24 * 25 * <p> 26 * Allows developers to run automated tests for their mobile applications on 27 * Google infrastructure.</p> 28 * 29 * <p> 30 * For more information about this service, see the API 31 * <a href="https://developers.google.com/cloud-test-lab/" target="_blank">Documentation</a> 32 * </p> 33 * 34 * @author Google, Inc. 35 */ 36class Testing extends \Google\Service 37{ 38 /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */ 39 const CLOUD_PLATFORM = 40 "https://www.googleapis.com/auth/cloud-platform"; 41 /** View your data across Google Cloud services and see the email address of your Google Account. */ 42 const CLOUD_PLATFORM_READ_ONLY = 43 "https://www.googleapis.com/auth/cloud-platform.read-only"; 44 45 public $applicationDetailService; 46 public $projects_testMatrices; 47 public $testEnvironmentCatalog; 48 49 /** 50 * Constructs the internal representation of the Testing service. 51 * 52 * @param Client|array $clientOrConfig The client used to deliver requests, or a 53 * config array to pass to a new Client instance. 54 * @param string $rootUrl The root URL used for requests to the service. 55 */ 56 public function __construct($clientOrConfig = [], $rootUrl = null) 57 { 58 parent::__construct($clientOrConfig); 59 $this->rootUrl = $rootUrl ?: 'https://testing.googleapis.com/'; 60 $this->servicePath = ''; 61 $this->batchPath = 'batch'; 62 $this->version = 'v1'; 63 $this->serviceName = 'testing'; 64 65 $this->applicationDetailService = new Testing\Resource\ApplicationDetailService( 66 $this, 67 $this->serviceName, 68 'applicationDetailService', 69 [ 70 'methods' => [ 71 'getApkDetails' => [ 72 'path' => 'v1/applicationDetailService/getApkDetails', 73 'httpMethod' => 'POST', 74 'parameters' => [], 75 ], 76 ] 77 ] 78 ); 79 $this->projects_testMatrices = new Testing\Resource\ProjectsTestMatrices( 80 $this, 81 $this->serviceName, 82 'testMatrices', 83 [ 84 'methods' => [ 85 'cancel' => [ 86 'path' => 'v1/projects/{projectId}/testMatrices/{testMatrixId}:cancel', 87 'httpMethod' => 'POST', 88 'parameters' => [ 89 'projectId' => [ 90 'location' => 'path', 91 'type' => 'string', 92 'required' => true, 93 ], 94 'testMatrixId' => [ 95 'location' => 'path', 96 'type' => 'string', 97 'required' => true, 98 ], 99 ], 100 ],'create' => [ 101 'path' => 'v1/projects/{projectId}/testMatrices', 102 'httpMethod' => 'POST', 103 'parameters' => [ 104 'projectId' => [ 105 'location' => 'path', 106 'type' => 'string', 107 'required' => true, 108 ], 109 'requestId' => [ 110 'location' => 'query', 111 'type' => 'string', 112 ], 113 ], 114 ],'get' => [ 115 'path' => 'v1/projects/{projectId}/testMatrices/{testMatrixId}', 116 'httpMethod' => 'GET', 117 'parameters' => [ 118 'projectId' => [ 119 'location' => 'path', 120 'type' => 'string', 121 'required' => true, 122 ], 123 'testMatrixId' => [ 124 'location' => 'path', 125 'type' => 'string', 126 'required' => true, 127 ], 128 ], 129 ], 130 ] 131 ] 132 ); 133 $this->testEnvironmentCatalog = new Testing\Resource\TestEnvironmentCatalog( 134 $this, 135 $this->serviceName, 136 'testEnvironmentCatalog', 137 [ 138 'methods' => [ 139 'get' => [ 140 'path' => 'v1/testEnvironmentCatalog/{environmentType}', 141 'httpMethod' => 'GET', 142 'parameters' => [ 143 'environmentType' => [ 144 'location' => 'path', 145 'type' => 'string', 146 'required' => true, 147 ], 148 'projectId' => [ 149 'location' => 'query', 150 'type' => 'string', 151 ], 152 ], 153 ], 154 ] 155 ] 156 ); 157 } 158} 159 160// Adding a class alias for backwards compatibility with the previous class name. 161class_alias(Testing::class, 'Google_Service_Testing'); 162