Skip to content

Commit

Permalink
build: use fully qualified request type name in tests (#554)
Browse files Browse the repository at this point in the history
* build: 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>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Sep 22, 2022
1 parent fe5f122 commit 33cf51f
Show file tree
Hide file tree
Showing 2 changed files with 192 additions and 144 deletions.
168 changes: 96 additions & 72 deletions packages/google-cloud-oslogin/test/gapic_os_login_service_v1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.DeletePosixAccountRequest()
);
const defaultValue1 = getTypeDefaultValue('DeletePosixAccountRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.DeletePosixAccountRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -205,9 +206,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.DeletePosixAccountRequest()
);
const defaultValue1 = getTypeDefaultValue('DeletePosixAccountRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.DeletePosixAccountRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -251,9 +253,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.DeletePosixAccountRequest()
);
const defaultValue1 = getTypeDefaultValue('DeletePosixAccountRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.DeletePosixAccountRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedError = new Error('expected');
Expand Down Expand Up @@ -281,9 +284,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.DeletePosixAccountRequest()
);
const defaultValue1 = getTypeDefaultValue('DeletePosixAccountRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.DeletePosixAccountRequest',
['name']
);
request.name = defaultValue1;
const expectedError = new Error('The client has already been closed.');
client.close();
Expand All @@ -301,9 +305,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.DeleteSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('DeleteSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.DeleteSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -332,9 +337,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.DeleteSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('DeleteSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.DeleteSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -378,9 +384,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.DeleteSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('DeleteSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.DeleteSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedError = new Error('expected');
Expand Down Expand Up @@ -408,9 +415,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.DeleteSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('DeleteSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.DeleteSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedError = new Error('The client has already been closed.');
client.close();
Expand All @@ -428,9 +436,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.GetLoginProfileRequest()
);
const defaultValue1 = getTypeDefaultValue('GetLoginProfileRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.GetLoginProfileRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -458,9 +467,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.GetLoginProfileRequest()
);
const defaultValue1 = getTypeDefaultValue('GetLoginProfileRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.GetLoginProfileRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -504,9 +514,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.GetLoginProfileRequest()
);
const defaultValue1 = getTypeDefaultValue('GetLoginProfileRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.GetLoginProfileRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedError = new Error('expected');
Expand Down Expand Up @@ -534,9 +545,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.GetLoginProfileRequest()
);
const defaultValue1 = getTypeDefaultValue('GetLoginProfileRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.GetLoginProfileRequest',
['name']
);
request.name = defaultValue1;
const expectedError = new Error('The client has already been closed.');
client.close();
Expand All @@ -554,9 +566,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.GetSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('GetSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.GetSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -584,9 +597,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.GetSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('GetSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.GetSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -630,9 +644,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.GetSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('GetSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.GetSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedError = new Error('expected');
Expand Down Expand Up @@ -660,9 +675,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.GetSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('GetSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.GetSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedError = new Error('The client has already been closed.');
client.close();
Expand All @@ -680,9 +696,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.ImportSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('ImportSshPublicKeyRequest', [
'parent',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.ImportSshPublicKeyRequest',
['parent']
);
request.parent = defaultValue1;
const expectedHeaderRequestParams = `parent=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -711,9 +728,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.ImportSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('ImportSshPublicKeyRequest', [
'parent',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.ImportSshPublicKeyRequest',
['parent']
);
request.parent = defaultValue1;
const expectedHeaderRequestParams = `parent=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -757,9 +775,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.ImportSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('ImportSshPublicKeyRequest', [
'parent',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.ImportSshPublicKeyRequest',
['parent']
);
request.parent = defaultValue1;
const expectedHeaderRequestParams = `parent=${defaultValue1}`;
const expectedError = new Error('expected');
Expand Down Expand Up @@ -787,9 +806,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.ImportSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('ImportSshPublicKeyRequest', [
'parent',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.ImportSshPublicKeyRequest',
['parent']
);
request.parent = defaultValue1;
const expectedError = new Error('The client has already been closed.');
client.close();
Expand All @@ -807,9 +827,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.UpdateSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('UpdateSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.UpdateSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -838,9 +859,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.UpdateSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('UpdateSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.UpdateSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedResponse = generateSampleMessage(
Expand Down Expand Up @@ -884,9 +906,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.UpdateSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('UpdateSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.UpdateSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedHeaderRequestParams = `name=${defaultValue1}`;
const expectedError = new Error('expected');
Expand Down Expand Up @@ -914,9 +937,10 @@ describe('v1.OsLoginServiceClient', () => {
const request = generateSampleMessage(
new protos.google.cloud.oslogin.v1.UpdateSshPublicKeyRequest()
);
const defaultValue1 = getTypeDefaultValue('UpdateSshPublicKeyRequest', [
'name',
]);
const defaultValue1 = getTypeDefaultValue(
'.google.cloud.oslogin.v1.UpdateSshPublicKeyRequest',
['name']
);
request.name = defaultValue1;
const expectedError = new Error('The client has already been closed.');
client.close();
Expand Down
Loading

0 comments on commit 33cf51f

Please sign in to comment.