googleapis/nodejs-pubsub

SchemaServiceClient close doesn't wait dependencies promises

thomasvargiu opened this issue · 1 comments

Hi,
The SchemaServiceClient doesn't wait iamClient to be closed.

See

stub.close();
this.iamClient.close();

Running some integration tests Jest returns the following error:

Jest did not exit one second after the test run has completed.

'This usually means that there are asynchronous operations that weren't stopped in your tests. Consider running Jest with `--detectOpenHandles` to troubleshoot this issue.

Usually it's not a real problem, but I think it should be better to wait all close operations.

That part of the client is generated code and is not specific to Pub/Sub. To get this change made, please file this issue under gapic-generator-typescript.

For reference, this change was added in this PR: googleapis/gapic-generator-typescript#953