From 46187da8dfa76a635698fe68141a16e480855874 Mon Sep 17 00:00:00 2001 From: Alexander Fenster Date: Mon, 27 Nov 2023 20:23:55 +0000 Subject: [PATCH] test: remove lint warnings from tests --- gax/test/system-test/test.clientlibs.ts | 25 ------------------------- gax/test/test-application/src/index.ts | 10 +++++----- 2 files changed, 5 insertions(+), 30 deletions(-) diff --git a/gax/test/system-test/test.clientlibs.ts b/gax/test/system-test/test.clientlibs.ts index 3733903ca..fcc14e761 100644 --- a/gax/test/system-test/test.clientlibs.ts +++ b/gax/test/system-test/test.clientlibs.ts @@ -165,14 +165,6 @@ async function runSystemTest( return await runScript(packageName, inMonorepo, 'system-test'); } -// nodejs-kms does not have system test. -async function runSamplesTest( - packageName: string, - inMonorepo: boolean -): Promise { - return await runScript(packageName, inMonorepo, 'samples-test'); -} - describe('Run system tests for some libraries', () => { before(async () => { console.log('Packing google-gax...'); @@ -218,21 +210,4 @@ describe('Run system tests for some libraries', () => { } }); }); - - // KMS api has IAM service injected from gax. All its IAM related test are in samples-test. - // KMS is in the google-cloud-node monorepo - // Temporarily skipped to avoid circular dependency issue. - /*describe('kms', () => { - before(async () => { - await preparePackage('kms', true); - }); - it('should pass samples tests', async function () { - const result = await runSamplesTest('kms', true); - if (result === TestResult.SKIP) { - this.skip(); - } else if (result === TestResult.FAIL) { - throw new Error('Test failed'); - } - }); - });*/ }); diff --git a/gax/test/test-application/src/index.ts b/gax/test/test-application/src/index.ts index 501a77f17..8d13f8618 100644 --- a/gax/test/test-application/src/index.ts +++ b/gax/test/test-application/src/index.ts @@ -495,7 +495,7 @@ async function testServerStreamingRetryOptions(client: SequenceServiceClient) { ); const response = await client.createStreamingSequence(request); - await new Promise((resolve, _) => { + await new Promise(resolve => { const sequence = response[0]; const attemptRequest = @@ -554,7 +554,7 @@ async function testServerStreamingRetrieswithRetryOptions( ); const response = await client.createStreamingSequence(request); - await new Promise((resolve, _) => { + await new Promise(resolve => { const sequence = response[0]; const attemptRequest = @@ -617,7 +617,7 @@ async function testServerStreamingRetriesWithShouldRetryFn( ); const response = await client.createStreamingSequence(request); - await new Promise((resolve, _) => { + await new Promise(resolve => { const sequence = response[0]; const attemptRequest = new protos.google.showcase.v1beta1.AttemptStreamingSequenceRequest(); @@ -676,7 +676,7 @@ async function testServerStreamingRetrieswithRetryRequestOptions( ); const response = await client.createStreamingSequence(request); - await new Promise((resolve, _) => { + await new Promise(resolve => { const sequence = response[0]; const attemptRequest = @@ -748,7 +748,7 @@ async function testServerStreamingRetrieswithRetryRequestOptionsResumptionStrate 'This is testing the brand new and shiny StreamingSequence server 3' ); const response = await client.createStreamingSequence(request); - await new Promise((resolve, _) => { + await new Promise(resolve => { const sequence = response[0]; const attemptRequest =