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

Get functional tests working against Dremio Cloud #47

Merged
merged 7 commits into from
Nov 22, 2022
Merged

Conversation

ravjotbrar
Copy link
Contributor

@ravjotbrar ravjotbrar commented Oct 24, 2022

Summary

Made changes to the tests to refer to the S3 bucket instead of the GCS bucket. The source name is still the same, but the root_path in the tests will now prefix the bucket name, instead of the source name. In addition, I've added a dremio cloud profile and dremio software profile to run the functional tests against. Since the privileges table is different in Dremio Software and Dremio Cloud, the grants macro needs to check which profile we're using in order to get data from the privileges table.

Description

Grants Macro

  • Check to see if we're using Dremio Cloud or Dremio Software as our host and set the privileges_table name accordingly
  • Quote the grantee user, as Dremio Cloud users have dots in their name

Functional Tests Configuration

  • Add a new parser option for pytest called --profile
  • Add two profile targets: dremio_cloud_target() and dremio_software_target()

These changes allow us to specify 'dremio_cloud' or 'dremio_software' as the profile when running the functional tests

Datalake Constant

  • Rename to 'BUCKET' and add another constant called 'SOURCE' to differentiate between the two in Dremio

Related Issue

Additional Reviewers

@jlarue26
@ArgusLi

@ravjotbrar ravjotbrar linked an issue Oct 24, 2022 that may be closed by this pull request
@ravjotbrar
Copy link
Contributor Author

workflow

@ravjotbrar ravjotbrar changed the title Create test workflow (WIP) Get functional tests working against Dremio Cloud Nov 20, 2022
Copy link
Contributor

@ArgusLi ArgusLi left a comment

Choose a reason for hiding this comment

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

Everything else looks amazing. I am very excited for these changes!

dbt/include/dremio/macros/adapters/apply_grants.sql Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants