Why is .env.local file not loaded in the test environment #499
Replies: 1 comment
-
|
👋 @jmflannery. See #418 for history and discussion. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I am curious why the
.env.localfile is not loaded in the test environment.I run my test environment more often on my local machine than on CI. The development and test environments on my local machine share the same database configuration.
I want to share the same
.env.localin my development and test environments. I prefer to check in the.envfile as an example with no values. Instead of having one.env.local, I usually need a.env.development.localand.env.test.localwith the same contents.I understand this is the intended behavior. Is there any file that could be shared between development and test with higher precedence than
.env?Thank you!
Edit: I did add the code as suggested into
application.rbto add.env.localto the files to be loaded, and it is working as expected.Beta Was this translation helpful? Give feedback.
All reactions