Fang-Yu Rao has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/22774 )

Change subject: IMPALA-13959: Fix 
TestHmsIntegration.test_change_parquet_column_type
......................................................................


Patch Set 2:

(1 comment)

I left a question which is only for my own understanding.

http://gerrit.cloudera.org:8080/#/c/22774/2/tests/metadata/test_hms_integration.py
File tests/metadata/test_hms_integration.py:

http://gerrit.cloudera.org:8080/#/c/22774/2/tests/metadata/test_hms_integration.py@a300
PS2, Line 300:
This is only for my understanding.

Is my understanding correct that after 'vector' was removed, the class method 
add_test_dimensions() will never be called, because of the following in 
https://github.com/apache/impala/blob/master/tests/conftest.py? It looks like 
we call cls.add_test_dimensions() only if we provide 'vector' when running a 
test. If this is the case, then do we still need to keep add_test_dimensions()?

def pytest_generate_tests(metafunc):
  """
  This is a hook to parameterize the tests based on the input vector.

  If a test has the 'vector' fixture specified, this code is invoked and it 
will build
  a set of test vectors to parameterize the test with.
  """
  # All Impala tests classes must inherit BaseTestSuite.
  assert issubclass(metafunc.cls, tests.common.base_test_suite.BaseTestSuite)
  assert metafunc.cls.default_test_protocol() in VALID_TEST_PROTOCOLS
  if 'vector' in metafunc.fixturenames:
    metafunc.cls.add_test_dimensions()
    vectors = metafunc.cls.ImpalaTestMatrix.generate_test_vectors(
        metafunc.config.option.exploration_strategy)

    if len(vectors) == 0:
      LOG.warning("No test vectors generated for test '%s'. Check constraints 
and "
          "input vectors" % metafunc.function.__name__)

    vector_names = list(map(str, vectors))
    # In the case this is a test result update or sanity run, select a single 
test vector
    # to run. This is okay for update_results because results are expected to 
be the same
    # for all test vectors.
    if metafunc.config.option.update_results or metafunc.config.option.sanity:
      vectors = vectors[0:1]
      vector_names = vector_names[0:1]
    metafunc.parametrize('vector', vectors, ids=vector_names)



--
To view, visit http://gerrit.cloudera.org:8080/22774
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If5fb9f96b4087e86b0ebaac7135e14b7a14936ea
Gerrit-Change-Number: 22774
Gerrit-PatchSet: 2
Gerrit-Owner: Riza Suminto <riza.sumi...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <csringho...@cloudera.com>
Gerrit-Reviewer: Fang-Yu Rao <fangyu....@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <impala-public-jenk...@cloudera.com>
Gerrit-Reviewer: Noemi Pap-Takacs <npaptak...@cloudera.com>
Gerrit-Reviewer: Riza Suminto <riza.sumi...@cloudera.com>
Gerrit-Comment-Date: Thu, 17 Apr 2025 01:20:06 +0000
Gerrit-HasComments: Yes

Reply via email to