forked from gatewayd-io/gatewayd
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix parameters camelCase support in loadEnvVars for environment varia…
…ble parsing (gatewayd-io#588) * Added mapenv JSON tag function and unit tests for server load balancer strategy configuration * Added `transformEnvVariable` function to format environment variable names based on JSON tags * Modified `loadEnvVars` to use the new `transformEnvVariable` function * Added `generateTagMapping` to create mappings from struct fields' JSON tags * Added unit test `ServerLoadBalancerStrategyOverwrite` to verify that the server load balancer strategy is set and loaded correctly from environment variables * Added unit test `pluginDefaultPolicyOverwrite` to verify that the plugin default policy is set and loaded correctly from environment variables * Added `initializeConfig` helper function to simplify configuration setup for tests * Updated `TestLoadEnvVariables` to include a scenario for server load balancer strategy overwrite * Updated comment for `generateTagMapping` function to clarify tag case handling
- Loading branch information
1 parent
359981c
commit 0127264
Showing
2 changed files
with
120 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters