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

Add tox #919

Merged
merged 41 commits into from
Aug 27, 2024
Merged

Add tox #919

merged 41 commits into from
Aug 27, 2024

Conversation

emmyoop
Copy link
Member

@emmyoop emmyoop commented Jun 11, 2024

resolves #920
resolves #948

Problem

We're using bash to run tests right now and want to standardize on tox so all tests can be run the same, regardless which method is being used for testing.

Solution

  1. Move /integration_tests/ci/sample.profiles.yml to /integration_tests and rename it to profiles.yml
  2. Rename env vars to be more standardized + update *.env files accordingly
  3. Add env var for schemas
  4. Update *.env files accordingly
  5. Add supported_adapters var and [testenv:list_supported_adapters] tox command to be able to determine what env vars to test. This allows the package maintainer to explicitly control what adapters should be tested without inferring it from the profile. This is useful during development or for iterative changes.
  6. Add tox.ini for running current tests.
  7. Update CircleCI test script to stop copying the profile over
  8. Added a github workflow to run tests in GitHub. CircleCI was left in place so we can verify tests for a small overlap period.

I did not rewrite the tests to use tox as it was out of scope for this exercise.

Checklist

  • This code is associated with an issue which has been triaged and accepted for development.
  • I have read the contributing guide and understand what's expected of me
  • 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 README.md (if applicable)

@emmyoop emmyoop changed the title Er/setup tox Add tox Jun 11, 2024
.circleci/config.yml Outdated Show resolved Hide resolved
tox.ini Outdated Show resolved Hide resolved
@emmyoop emmyoop requested a review from dbeatty10 June 27, 2024 20:29
@emmyoop emmyoop force-pushed the er/setup-tox branch 3 times, most recently from 0f901aa to 30bfa75 Compare July 2, 2024 15:13
@dbeatty10 dbeatty10 added the enhancement New feature or request label Jul 2, 2024
@emmyoop emmyoop closed this Jul 3, 2024
@emmyoop emmyoop reopened this Jul 3, 2024
Copy link
Contributor

@dbeatty10 dbeatty10 left a comment

Choose a reason for hiding this comment

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

Looks good to me.

We'll do a follow-up later to remove the CircleCI workflows and just use CI via GitHub Actions.

@emmyoop emmyoop added this pull request to the merge queue Aug 27, 2024
Merged via the queue into main with commit 4feda1c Aug 27, 2024
13 checks passed
@emmyoop
Copy link
Member Author

emmyoop commented Sep 5, 2024

Related to dbt-labs/dbt-core#10668

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add tox-based Integration Testing support for this package Tox for running CI tests
2 participants