backend: Tests: Add regression test for ApplyMeDefaults trimming#5699
backend: Tests: Add regression test for ApplyMeDefaults trimming#5699nikunjkumar05 wants to merge 1 commit into
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: nikunjkumar05 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
|
|
Welcome @nikunjkumar05! |
|
@nikunjkumar05 , the CLA check is failing because the Contributor License Agreement hasn’t been signed yet. Please open the authorization/agreement link provided by EasyCLA and complete the signing process. Once done, the CLA check should pass automatically. |
Oh Thanks |
illume
left a comment
There was a problem hiding this comment.
Thanks for working on this.
The commit messages could use some tidying up to match our contribution guidelines. We use Linux kernel style — the contributing guide has the details, and git log shows good examples.
Commits that need attention
backend: add a simple ApplyMeDefaults testcase— Description must start with a capital letter — e.g.frontend: HomeButton: Fix the buttonnotfrontend: HomeButton: fix the button.
Commit guidelines
- Use atomic commits focused on a single change.
- Use the title format
<area>: <Description of changes>— description must start with a capital letter. - Keep the title under 72 characters (soft requirement).
- Explain the intention and why the change is needed.
- Make commit titles meaningful and describe what changed.
- Do not add code that a later commit rewrites; squash or reorder commits instead.
- Do not include
Fixes #NNin commit messages.
Good examples:
frontend: HomeButton: Fix so it navigates to homebackend: config: Add enable-dynamic-clusters flag
There was a problem hiding this comment.
Pull request overview
Adds a single regression unit test verifying that ApplyMeDefaults trims surrounding whitespace from each of its four inputs and returns the trimmed values unchanged when they are non-empty.
Changes:
- New test
TestApplyMeDefaults_TrimsWhitespaceinbackend/pkg/config/config_test.gocovering whitespace trimming on all four arguments.
|
Thanks I'll will take care of it |
Summary
Adds one small regression test for
ApplyMeDefaultsto confirm it trims surrounding whitespace and returns the expected values.Related Issue
NA
Changes
TestApplyMeDefaults_TrimsWhitespaceinconfig_test.goSteps to Test
cd backendgo test ./pkg/config -run TestApplyMeDefaults_TrimsWhitespace -v