Skip to content

Tests should ensure clients are closed no matter what the outcome of a test is #239

Closed
@rlubke

Description

@rlubke

I recently added missing close() calls to tests that didn't include them, however, there are cases where a test expects an exception to be thrown and handled by the testng framework or the test could fail for some other reason which would leave a client open as the close() call would be skipped.

We could:

  • wrap all close() calls in a finally block.
  • use setup and teardown (the names may not be right) to initialize/shutdown the client.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions