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

test(@nestjs/config) add more tests for priority #1666

Conversation

bejewel-kyoungmin
Copy link
Contributor

@bejewel-kyoungmin bejewel-kyoungmin commented Mar 22, 2024

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Other... Please describe:

What is the current behavior?

Issue Number: N/A

What is the new behavior?

I have a curiosity to see how config module works.
I think nestjs documents don't provide enough explanations.
If both .env file and load configration are provided, load configuration override .env vars?
If multiple load configrations are provided, last configuration take precedence?
That's why I add a couple of tests.

These tests answer following questions.
both .env file and load configuration, what's the priority?
multiple load configurations, what's the priority?

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

These answer following questions.
both .env file and load configuration, what's the priority?
both multiple load configurations, what's the priority?
@kamilmysliwiec kamilmysliwiec merged commit 93e5f70 into nestjs:master Mar 25, 2024
1 check passed
@kamilmysliwiec
Copy link
Member

lgtm

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

Successfully merging this pull request may close these issues.

2 participants