Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-2435

Refactor SqlTestFactory

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.17.0
    • Fix Version/s: 1.18.0
    • Component/s: core
    • Labels:
      None

      Description

      Current SqlTestFactory/DelegatingSqlTestFactory is hard to reason about, and it is hard to extend/cache properly.

      There are three key changes here:

      1. Rename DefaultSqlTestFactory to SqlTestFactory. SqlTestFactory was an interface, however it has a single viable implementation, so it makes little sense to keep it as is.
      2. Move MockCatalogReader.init and MockCatalogReader.init2 to MockCatalogReaderSimple and MockCatalogReaderExtended
      3. Move MockCatalogReader to its own package, and split several inner classes to a top-level ones.
      4. Replace usages

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                julianhyde Julian Hyde
                Reporter:
                vladimirsitnikov Vladimir Sitnikov
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: