-
Notifications
You must be signed in to change notification settings - Fork 213
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 reading test-specific environment from *ENV.dhall file #2268
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see much to complain about, but I'm not very familiar with the context, so I'd prefer if @Gabriel439 could review this too.
dhall/tests/Dhall/Test/Util.hs
Outdated
setEnv :: (Text, Text) -> IO (Text, Maybe Text) | ||
setEnv (k, v) = do | ||
old <- Turtle.need k | ||
_ <- putStrLn $ Text.unpack $ "Setting env: "<>k <> "="<>v |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If needed, such logging should go to stderr.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would omit the logging here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Just one comment
dhall/tests/Dhall/Test/Util.hs
Outdated
setEnv :: (Text, Text) -> IO (Text, Maybe Text) | ||
setEnv (k, v) = do | ||
old <- Turtle.need k | ||
_ <- putStrLn $ Text.unpack $ "Setting env: "<>k <> "="<>v |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would omit the logging here
This will be a new requirement for the standard test suite as part of dhall-lang/dhall-lang#1192
I did this on my WIP branch (#2236), but it seems independent enough to review early.