Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-13319

Avoid duplicate exec option declaration in py.test

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • Impala 4.4.0
    • Impala 4.5.0
    • Test
    • None

    Description

      add_mandatory_exec_option() may replace existing option values in 'exec_option' dimension, and may cause unintended test vector duplication. For example, the following declaration will create two duplicate test vector, both with "disable_codegen=False":

          cls.ImpalaTestMatrix.add_dimension(create_exec_option_dimension(
            disable_codegen_options=[False, True]))
          add_mandatory_exec_option(cls, "disable_codegen", False)

       

      add_exec_option_dimension() will create new test dimension for a 'key', but does not insert it into 'exec_option' dimension until vector generation later. It also does not validate if 'key' already exist in 'exec_option' dimension. This can confuse test writer when they need to write constraint, because they might look for the value at vector.get_value('exec_option')['key'] instead of vector.get_value('key'), and vice versa.

      Attachments

        Activity

          People

            rizaon Riza Suminto
            rizaon Riza Suminto
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: