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

Feature/schema tests are more unique #3335

Merged
merged 4 commits into from
May 13, 2021

Conversation

iknox-fa
Copy link
Contributor

@iknox-fa iknox-fa commented May 10, 2021

resolves #3254

Description

Adds a 10 character hash to the unique_id of all schema (generic) tests. This ensures that if a test differs only in it's hash components, it will still be run instead of clobbered by the last test defined.

There's a few bits I'd like feedback about from the team. I tagged them with TODOs, but I'll put a comment in the PR as well. <- complete.

Checklist

  • I have signed the CLA
  • I have run this code in development and it appears to resolve the stated issue
  • This PR includes tests, or tests are not required/relevant for this PR
  • I have updated the CHANGELOG.md and added information about my change to the "dbt next" section.

core/dbt/exceptions.py Outdated Show resolved Hide resolved
core/dbt/parser/schemas.py Outdated Show resolved Hide resolved
Copy link
Contributor

@jtcohen6 jtcohen6 left a comment

Choose a reason for hiding this comment

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

@iknox-fa This is coming along really nicely! Thanks for the inline comments, it was really easy to follow your reasoning

core/dbt/parser/schemas.py Outdated Show resolved Hide resolved
core/dbt/parser/schemas.py Outdated Show resolved Hide resolved
core/dbt/exceptions.py Outdated Show resolved Hide resolved
core/dbt/exceptions.py Outdated Show resolved Hide resolved
Copy link
Contributor

@nathaniel-may nathaniel-may left a comment

Choose a reason for hiding this comment

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

Some relatively minor points I'd like to discuss before merging. Otherwise it looks pretty good.

core/dbt/parser/schemas.py Show resolved Hide resolved
core/dbt/parser/schemas.py Show resolved Hide resolved
core/dbt/parser/schemas.py Outdated Show resolved Hide resolved
core/dbt/parser/schemas.py Show resolved Hide resolved
@nathaniel-may nathaniel-may self-requested a review May 12, 2021 19:04
@kwigley kwigley self-requested a review May 12, 2021 19:27
Copy link
Contributor

@gshank gshank left a comment

Choose a reason for hiding this comment

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

Lots of good comments already! Looks good.

Copy link
Contributor

@kwigley kwigley left a comment

Choose a reason for hiding this comment

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

lgtm 👍

@iknox-fa iknox-fa merged commit 1f33b6a into develop May 13, 2021
@iknox-fa iknox-fa deleted the feature/schema_tests_are_more_unique branch May 13, 2021 00:18
@jtcohen6 jtcohen6 mentioned this pull request Mar 23, 2022
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Better unique_id construction for specific instances of generic tests
5 participants