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

Support for models that use ephemeral models (mocking input to the ephemeral models) #80

Open
clairetaylor352 opened this issue May 25, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@clairetaylor352
Copy link

Describe the feature

I assume that what I'm about to describe isn't supported right now, as I can't get it to work.

I have a model (A) that uses an ephemeral model (B), that in turn also uses an ephemeral model. (C). Model C uses a regular model (D) I'd like to unit test A, and mock the input from D, since ephemeral models are effectively just CTEs under the hood.

I get an error:
12:08:46 002003 (42S02): SQL compilation error:
12:08:46 Object '__DBT__CTE__B' does not exist or not authorized.

When I tried this on the off chance that it might work!

Describe alternatives you've considered

Mocking and testing the ephemeral models, this is annoying for me though as they have array inputs and outputs, so it's fiddly.

Additional context

I don't think it will be DB specific, but I am using Snowflake.

Who will this benefit?

Anyone who wants to do what I describe above.

Are you interested in contributing this feature?

I could do, but I'm not sure where to start!

@clairetaylor352 clairetaylor352 added the enhancement New feature or request label May 25, 2023
@mjirv
Copy link
Owner

mjirv commented Jun 4, 2023

Taking a look at this. Would you be able to post your test yaml for when you tried this but got the error above?

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

No branches or pull requests

2 participants