Skip to content

fix: normalise xmlns attribute placement in New-PlasterManifest for PS5.1#464

Merged
HeyItsGilbert merged 1 commit into
mainfrom
fix/ps51-xmlns-placement
May 26, 2026
Merged

fix: normalise xmlns attribute placement in New-PlasterManifest for PS5.1#464
HeyItsGilbert merged 1 commit into
mainfrom
fix/ps51-xmlns-placement

Conversation

@HeyItsGilbert
Copy link
Copy Markdown
Member

Closes #461

Summary

  • PS5.1's .NET XML serializer ignores XmlWriterSettings.NewLineOnAttributes for namespace declarations, emitting xmlns inline instead of on its own indented line
  • After $xmlWriter.Dispose(), reads the written file back and applies a regex substitution to move an inline xmlns= attribute onto its own line, matching the format the tests expect
  • A $wroteFile flag gates the post-processing so it only runs when ShouldProcess returned true (skipped in -WhatIf mode)

Test plan

  • Run Pester suite on PS5.1 — all four New-PlasterManifest "Generates a valid manifest" tests pass
  • Run Pester suite on PS7 — no regression

🤖 Generated with Claude Code

…S5.1 compat (#461)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

Test Results

  4 files  284 suites   1m 1s ⏱️
243 tests 237 ✅ 2 💤 4 ❌
972 runs  960 ✅ 8 💤 4 ❌

For more details on these failures, see this check.

Results for commit c9573e0.

@HeyItsGilbert HeyItsGilbert merged commit 64dc31c into main May 26, 2026
5 of 7 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.

fix: New-PlasterManifest xmlns attribute placement differs on PS5.1

1 participant