Summary
Add an exact-output assertion to TestReplaceVeleroWithOADP_ScheduleCreateVerbFirst in cmd/root_test.go.
Required change
Keep the existing checks for the removal of velero create schedule and the occurrence count. Also compare cmd.Example with the complete expected normalized example string. The failure output must show the expected and actual strings.
Rationale
The occurrence-count check verifies only part of the replacement. An exact-output assertion verifies the complete transformed command text, including both velero create schedule NAME replacements and the surrounding content.
Affected area
cmd/root_test.go
TestReplaceVeleroWithOADP_ScheduleCreateVerbFirst
Acceptance criteria
- The test declares the complete expected normalized example text.
- The test compares
cmd.Example to that expected text.
- A test failure reports both the expected and actual values.
- Existing relevant assertions remain valid or are replaced by the exact-output assertion where redundant.
Backlinks
Summary
Add an exact-output assertion to
TestReplaceVeleroWithOADP_ScheduleCreateVerbFirstincmd/root_test.go.Required change
Keep the existing checks for the removal of
velero create scheduleand the occurrence count. Also comparecmd.Examplewith the complete expected normalized example string. The failure output must show the expected and actual strings.Rationale
The occurrence-count check verifies only part of the replacement. An exact-output assertion verifies the complete transformed command text, including both
velero create schedule NAMEreplacements and the surrounding content.Affected area
cmd/root_test.goTestReplaceVeleroWithOADP_ScheduleCreateVerbFirstAcceptance criteria
cmd.Exampleto that expected text.Backlinks