Skip to content

Commit 419d09b

Browse files
gcf-owl-bot[bot]alexander-fenstergcf-merge-on-green[bot]
authored
build: use fully qualified request type name in tests (#786)
* feat: accept google-gax instance as a parameter Please see the documentation of the client constructor for details. PiperOrigin-RevId: 470332808 Source-Link: googleapis/googleapis@d4a2367 Source-Link: googleapis/googleapis-gen@e97a1ac Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZTk3YTFhYzIwNGVhZDRmZTczNDFmOTFlNzJkYjdjNmFjNjAxNjM0MSJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * fix: use _gaxModule when accessing gax for bundling PiperOrigin-RevId: 470911839 Source-Link: googleapis/googleapis@3527566 Source-Link: googleapis/googleapis-gen@f16a1d2 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZjE2YTFkMjI0ZjAwYTYzMGVhNDNkNmE5YTFhMzFmNTY2ZjQ1Y2RlYSJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * feat: Update Compute Engine API to revision 20220831 (#729) Source-Link: googleapis/googleapis@63c3007 Source-Link: googleapis/googleapis-gen@b658223 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiYjY1ODIyMzFhZTdiN2Y1Y2QxOGY3ZDE0MmM2NTQyMTc3M2NjYTVkZSJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * chore: use gapic-generator-typescript v2.17.0 PiperOrigin-RevId: 474338479 Source-Link: googleapis/googleapis@d5d35e0 Source-Link: googleapis/googleapis-gen@efcd3f9 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZWZjZDNmOTM5NjJhMTAzZjY4ZjAwM2UyYTFlZWNkZTZmYTIxNmEyNyJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * test: use fully qualified request type name in tests PiperOrigin-RevId: 475685359 Source-Link: googleapis/googleapis@7a12973 Source-Link: googleapis/googleapis-gen@370c729 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMzcwYzcyOWUyYmEwNjJhMTY3NDQ5YzI3ODgyYmE1ZjM3OWM1YzM0ZCJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: Alexander Fenster <[email protected]> Co-authored-by: gcf-merge-on-green[bot] <60162190+gcf-merge-on-green[bot]@users.noreply.github.com>
1 parent 29543d4 commit 419d09b

File tree

224 files changed

+85988
-38454
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

224 files changed

+85988
-38454
lines changed

packages/google-cloud-compute/protos/google/cloud/compute/v1/compute.proto

+874-54
Large diffs are not rendered by default.

packages/google-cloud-compute/protos/protos.d.ts

+4,033
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/google-cloud-compute/protos/protos.js

+12,082-1,938
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/google-cloud-compute/protos/protos.json

+2,190-332
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
// Copyright 2022 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// https://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
//
15+
// ** This file is automatically generated by gapic-generator-typescript. **
16+
// ** https://github.com/googleapis/gapic-generator-typescript **
17+
// ** All changes to this file may be overwritten. **
18+
19+
20+
21+
'use strict';
22+
23+
function main(project, region, regionSetLabelsRequestResource, resource) {
24+
// [START compute_v1_generated_Addresses_SetLabels_async]
25+
/**
26+
* This snippet has been automatically generated and should be regarded as a code template only.
27+
* It will require modifications to work.
28+
* It may require correct/in-range values for request initialization.
29+
* TODO(developer): Uncomment these variables before running the sample.
30+
*/
31+
/**
32+
* Project ID for this request.
33+
*/
34+
// const project = 'my-project'
35+
/**
36+
* The region for this request.
37+
*/
38+
// const region = 'us-central1'
39+
/**
40+
* The body resource for this request
41+
*/
42+
// const regionSetLabelsRequestResource = {}
43+
/**
44+
* An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
45+
*/
46+
// const requestId = 'abc123'
47+
/**
48+
* Name or id of the resource for this request.
49+
*/
50+
// const resource = 'abc123'
51+
52+
// Imports the Compute library
53+
const {AddressesClient} = require('@google-cloud/compute').v1;
54+
55+
// Instantiates a client
56+
const computeClient = new AddressesClient();
57+
58+
async function callSetLabels() {
59+
// Construct request
60+
const request = {
61+
project,
62+
region,
63+
regionSetLabelsRequestResource,
64+
resource,
65+
};
66+
67+
// Run request
68+
const response = await computeClient.setLabels(request);
69+
console.log(response);
70+
}
71+
72+
callSetLabels();
73+
// [END compute_v1_generated_Addresses_SetLabels_async]
74+
}
75+
76+
process.on('unhandledRejection', err => {
77+
console.error(err.message);
78+
process.exitCode = 1;
79+
});
80+
main(...process.argv.slice(2));
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
// Copyright 2022 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// https://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
//
15+
// ** This file is automatically generated by gapic-generator-typescript. **
16+
// ** https://github.com/googleapis/gapic-generator-typescript **
17+
// ** All changes to this file may be overwritten. **
18+
19+
20+
21+
'use strict';
22+
23+
function main(project, resource) {
24+
// [START compute_v1_generated_BackendServices_GetIamPolicy_async]
25+
/**
26+
* This snippet has been automatically generated and should be regarded as a code template only.
27+
* It will require modifications to work.
28+
* It may require correct/in-range values for request initialization.
29+
* TODO(developer): Uncomment these variables before running the sample.
30+
*/
31+
/**
32+
* Requested IAM Policy version.
33+
*/
34+
// const optionsRequestedPolicyVersion = 1234
35+
/**
36+
* Project ID for this request.
37+
*/
38+
// const project = 'my-project'
39+
/**
40+
* Name or id of the resource for this request.
41+
*/
42+
// const resource = 'abc123'
43+
44+
// Imports the Compute library
45+
const {BackendServicesClient} = require('@google-cloud/compute').v1;
46+
47+
// Instantiates a client
48+
const computeClient = new BackendServicesClient();
49+
50+
async function callGetIamPolicy() {
51+
// Construct request
52+
const request = {
53+
project,
54+
resource,
55+
};
56+
57+
// Run request
58+
const response = await computeClient.getIamPolicy(request);
59+
console.log(response);
60+
}
61+
62+
callGetIamPolicy();
63+
// [END compute_v1_generated_BackendServices_GetIamPolicy_async]
64+
}
65+
66+
process.on('unhandledRejection', err => {
67+
console.error(err.message);
68+
process.exitCode = 1;
69+
});
70+
main(...process.argv.slice(2));
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
// Copyright 2022 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// https://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
//
15+
// ** This file is automatically generated by gapic-generator-typescript. **
16+
// ** https://github.com/googleapis/gapic-generator-typescript **
17+
// ** All changes to this file may be overwritten. **
18+
19+
20+
21+
'use strict';
22+
23+
function main(globalSetPolicyRequestResource, project, resource) {
24+
// [START compute_v1_generated_BackendServices_SetIamPolicy_async]
25+
/**
26+
* This snippet has been automatically generated and should be regarded as a code template only.
27+
* It will require modifications to work.
28+
* It may require correct/in-range values for request initialization.
29+
* TODO(developer): Uncomment these variables before running the sample.
30+
*/
31+
/**
32+
* The body resource for this request
33+
*/
34+
// const globalSetPolicyRequestResource = {}
35+
/**
36+
* Project ID for this request.
37+
*/
38+
// const project = 'my-project'
39+
/**
40+
* Name or id of the resource for this request.
41+
*/
42+
// const resource = 'abc123'
43+
44+
// Imports the Compute library
45+
const {BackendServicesClient} = require('@google-cloud/compute').v1;
46+
47+
// Instantiates a client
48+
const computeClient = new BackendServicesClient();
49+
50+
async function callSetIamPolicy() {
51+
// Construct request
52+
const request = {
53+
globalSetPolicyRequestResource,
54+
project,
55+
resource,
56+
};
57+
58+
// Run request
59+
const response = await computeClient.setIamPolicy(request);
60+
console.log(response);
61+
}
62+
63+
callSetIamPolicy();
64+
// [END compute_v1_generated_BackendServices_SetIamPolicy_async]
65+
}
66+
67+
process.on('unhandledRejection', err => {
68+
console.error(err.message);
69+
process.exitCode = 1;
70+
});
71+
main(...process.argv.slice(2));
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
// Copyright 2022 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// https://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
//
15+
// ** This file is automatically generated by gapic-generator-typescript. **
16+
// ** https://github.com/googleapis/gapic-generator-typescript **
17+
// ** All changes to this file may be overwritten. **
18+
19+
20+
21+
'use strict';
22+
23+
function main(globalSetLabelsRequestResource, project, resource) {
24+
// [START compute_v1_generated_GlobalAddresses_SetLabels_async]
25+
/**
26+
* This snippet has been automatically generated and should be regarded as a code template only.
27+
* It will require modifications to work.
28+
* It may require correct/in-range values for request initialization.
29+
* TODO(developer): Uncomment these variables before running the sample.
30+
*/
31+
/**
32+
* The body resource for this request
33+
*/
34+
// const globalSetLabelsRequestResource = {}
35+
/**
36+
* Project ID for this request.
37+
*/
38+
// const project = 'my-project'
39+
/**
40+
* Name or id of the resource for this request.
41+
*/
42+
// const resource = 'abc123'
43+
44+
// Imports the Compute library
45+
const {GlobalAddressesClient} = require('@google-cloud/compute').v1;
46+
47+
// Instantiates a client
48+
const computeClient = new GlobalAddressesClient();
49+
50+
async function callSetLabels() {
51+
// Construct request
52+
const request = {
53+
globalSetLabelsRequestResource,
54+
project,
55+
resource,
56+
};
57+
58+
// Run request
59+
const response = await computeClient.setLabels(request);
60+
console.log(response);
61+
}
62+
63+
callSetLabels();
64+
// [END compute_v1_generated_GlobalAddresses_SetLabels_async]
65+
}
66+
67+
process.on('unhandledRejection', err => {
68+
console.error(err.message);
69+
process.exitCode = 1;
70+
});
71+
main(...process.argv.slice(2));
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
// Copyright 2022 Google LLC
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// https://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
//
15+
// ** This file is automatically generated by gapic-generator-typescript. **
16+
// ** https://github.com/googleapis/gapic-generator-typescript **
17+
// ** All changes to this file may be overwritten. **
18+
19+
20+
21+
'use strict';
22+
23+
function main(project, region, regionSetLabelsRequestResource, resource) {
24+
// [START compute_v1_generated_InterconnectAttachments_SetLabels_async]
25+
/**
26+
* This snippet has been automatically generated and should be regarded as a code template only.
27+
* It will require modifications to work.
28+
* It may require correct/in-range values for request initialization.
29+
* TODO(developer): Uncomment these variables before running the sample.
30+
*/
31+
/**
32+
* Project ID for this request.
33+
*/
34+
// const project = 'my-project'
35+
/**
36+
* The region for this request.
37+
*/
38+
// const region = 'us-central1'
39+
/**
40+
* The body resource for this request
41+
*/
42+
// const regionSetLabelsRequestResource = {}
43+
/**
44+
* An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported ( 00000000-0000-0000-0000-000000000000).
45+
*/
46+
// const requestId = 'abc123'
47+
/**
48+
* Name or id of the resource for this request.
49+
*/
50+
// const resource = 'abc123'
51+
52+
// Imports the Compute library
53+
const {InterconnectAttachmentsClient} = require('@google-cloud/compute').v1;
54+
55+
// Instantiates a client
56+
const computeClient = new InterconnectAttachmentsClient();
57+
58+
async function callSetLabels() {
59+
// Construct request
60+
const request = {
61+
project,
62+
region,
63+
regionSetLabelsRequestResource,
64+
resource,
65+
};
66+
67+
// Run request
68+
const response = await computeClient.setLabels(request);
69+
console.log(response);
70+
}
71+
72+
callSetLabels();
73+
// [END compute_v1_generated_InterconnectAttachments_SetLabels_async]
74+
}
75+
76+
process.on('unhandledRejection', err => {
77+
console.error(err.message);
78+
process.exitCode = 1;
79+
});
80+
main(...process.argv.slice(2));

0 commit comments

Comments
 (0)