Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xform: reorganize rules and tests for consistency #55654

Merged
merged 2 commits into from
Oct 20, 2020

Conversation

mgartner
Copy link
Collaborator

xform: organize rules by the type of expressions they match

This commit organizes exploration rules by the type of expressions they
match. GenerateZigzagJoins and GenerateInvertedZigzagJoins have been
moved to select.opt. All other rules were correctly organized.

Release note: None

xform: reorganize tests to match the organization of the rules

This commit moves around (and makes some minor necessary changes) to
exploration tests so that tests for rules in foo.opt can be found in
testdata/foo. Most of the changes were related to zigzag join rules
which moved from join to select, and some tests for
GenerateConstrainedScans that have lived in scan for years.

The goal of this change is to make it easier to find tests for a
specific rule and to set a precedent for future tests.

Release note: None

@mgartner mgartner requested a review from a team as a code owner October 17, 2020 00:44
@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Member

@RaduBerinde RaduBerinde left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

Reviewed 2 of 2 files at r1, 4 of 4 files at r2.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @rytaft)

This commit organizes exploration rules by the type of expressions they
match. `GenerateZigzagJoins` and `GenerateInvertedZigzagJoins` have been
moved to `select.opt`. All other rules were correctly organized.

Release note: None
This commit moves around (and makes some minor necessary changes) to
exploration tests so that tests for rules in `foo.opt` can be found in
`testdata/foo`. Most of the changes were related to zigzag join rules
which moved from `join` to `select`, and some tests for
`GenerateConstrainedScans` that have lived in `scan` for years.

The goal of this change is to make it easier to find tests for a
specific rule and to set a precedent for future tests.

Release note: None
@mgartner
Copy link
Collaborator Author

bors r=RaduBerinde

@craig
Copy link
Contributor

craig bot commented Oct 20, 2020

Build failed (retrying...):

@craig
Copy link
Contributor

craig bot commented Oct 20, 2020

Build succeeded:

@craig craig bot merged commit e25436f into cockroachdb:master Oct 20, 2020
@mgartner mgartner deleted the xform-refactor branch October 20, 2020 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants