Skip to content

fix: update FileVersionInfos when calling CopyTo, MoveTo and Replace on a IFileInfo#1455

Merged
vbreuss merged 1 commit intoTestableIO:mainfrom
FrancescoLuzzi:fix/maintain_version_infos
Apr 9, 2026
Merged

fix: update FileVersionInfos when calling CopyTo, MoveTo and Replace on a IFileInfo#1455
vbreuss merged 1 commit intoTestableIO:mainfrom
FrancescoLuzzi:fix/maintain_version_infos

Conversation

@FrancescoLuzzi
Copy link
Copy Markdown
Contributor

This PR fixes an issue where copying, moving or replacing a file would lose all the FileVersionInfo informations when using a MockFileSystem

Changes:

  • When creating a new MockFileData also copy the FileVersionInfo
  • Added tests to validate the fix

Open questions:

  • should FileVersionInfo be cloned or is the current fix enough?

@FrancescoLuzzi FrancescoLuzzi force-pushed the fix/maintain_version_infos branch from 602af4b to eda19eb Compare April 9, 2026 13:49
Copy link
Copy Markdown
Member

@vbreuss vbreuss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @FrancescoLuzzi, Looks good to me. I don't think it is necessary to clone the FileVersionInfo.

@vbreuss vbreuss merged commit 16aa745 into TestableIO:main Apr 9, 2026
10 checks passed
@github-actions github-actions bot added the state: released Issues that are released label Apr 9, 2026
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 9, 2026

This is addressed in release v22.1.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

state: released Issues that are released

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants