Skip to content

fix normalieze manifests issue#585

Merged
yxxhero merged 3 commits into
masterfrom
fix-normalize-manifests-issue
Jun 15, 2026
Merged

fix normalieze manifests issue#585
yxxhero merged 3 commits into
masterfrom
fix-normalize-manifests-issue

Conversation

@yxxhero

@yxxhero yxxhero commented Apr 2, 2024

Copy link
Copy Markdown
Collaborator

This pull request includes changes to the manifest/parse.go and manifest/parse_test.go files to improve the normalization of YAML content and add corresponding tests.

Improvements to YAML normalization:

  • manifest/parse.go: Refactored the normalization logic into a new function ContentNormalizeManifests to enhance code readability and maintainability. [1] [2]

Testing enhancements:

  • manifest/parse_test.go: Added a new test function TestContentNormalizeManifests to ensure the ContentNormalizeManifests function works correctly with various input scenarios.

Signed-off-by: yxxhero <aiopsclub@163.com>
@yxxhero yxxhero marked this pull request as draft December 17, 2024 23:45
yxxhero added 2 commits June 15, 2026 08:07
…ests-issue

# Conflicts:
#	manifest/parse.go
#	manifest/parse_test.go
- Rename ContentNormalizeManifests to unexported normalizeContent
  (avoids widening the public API; name avoids clash with the
  normalizeManifests bool parameter)
- Move the test into an internal package (manifest) to access the
  unexported helper
- Add an error-path case (sequence cannot unmarshal into map)
- Use require.NoError/require.Error and direct []byte comparison

Signed-off-by: yxxhero <aiopsclub@163.com>
@yxxhero yxxhero marked this pull request as ready for review June 15, 2026 00:19
@yxxhero yxxhero merged commit b908027 into master Jun 15, 2026
4 checks passed
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.

1 participant