MCPcopy Create free account
hub / github.com/apache/impala / setup_method

Method setup_method

tests/common/impala_test_suite.py:359–370  ·  view source on GitHub ↗

Setup for all test method. All classes inheriting from this class with a custom setup_method() must call this ImpalaTestSuite::setup_method() either via their super() or directly (same for teardown_method()).

(self, test_method)

Source from the content-addressed store, hash-verified

357 cls.close_impala_clients()
358
359 def setup_method(self, test_method): # noqa: U100
360 """
361 Setup for all test method. All classes inheriting from this class with a custom
362 setup_method() must call this ImpalaTestSuite::setup_method() either via their
363 super() or directly (same for teardown_method()).
364 """
365 # List of clients to be closed at the end of the test method. This avoids resource
366 # leaks of clients and sessions. This is protected by a lock to avoid concurrent
367 # modification
368 self.test_method_scoped_clients_lock = Lock()
369 self.test_method_scoped_clients = []
370 self._reset_impala_clients()
371
372 def teardown_method(self, test_method): # noqa: U100
373 """

Callers

nothing calls this directly

Calls 2

_reset_impala_clientsMethod · 0.95
LockFunction · 0.85

Tested by

no test coverage detected