Repository navigation
Add tests to BackupFS for metadata reuse and error handling - #81
Merged
Merged
Conversation
john-behm-bertelsmann
commented
Oct 8, 2026
Collaborator
- Implemented TestBackupFS_CreateAvoidsDuplicateLstat to ensure Lstat is not called multiple times during file creation.
- Added TestBackupFS_RejectsEmptyPath to verify that operations with empty paths return appropriate errors.
- Created TestBackupFS_CreateNormalizesUncleanPath to check path normalization during file creation.
- Introduced TestBackupFS_OpenFileAvoidsDuplicateLstat to confirm Lstat calls are minimized when opening files.
- Added TestBackupFS_RemoveAllReusesObservedMetadata to ensure metadata is reused during removal operations.
- Implemented TestBackupFS_RemoveAllPreservesErrorsAndRollback to verify error handling during removal.
- Created TestBackupFS_RenameOverwriteRollback to check rollback functionality during renaming.
- Added TestBackupFS_RenameAvoidsDuplicateLstat to ensure efficient metadata handling during renaming.
- Implemented TestBackupFS_SymlinkReusesResolvedMetadata to confirm symlink creation reuses metadata.
- Added TestBackupFS_MkdirReusesResolvedMetadata to ensure directory creation reuses metadata.
- Implemented TestBackupFS_ChmodAvoidsDuplicateLstat and TestBackupFS_ChownAvoidsDuplicateLstat to minimize Lstat calls during permission changes.
- Created TestBackupFS_ChtimesAvoidsDuplicateLstat to ensure efficient handling of modification times.
- Added utility type lstatCountingFS to count Lstat calls for testing purposes.
- Implemented TestBackupFS_CreateAvoidsDuplicateLstat to ensure Lstat is not called multiple times during file creation. - Added TestBackupFS_RejectsEmptyPath to verify that operations with empty paths return appropriate errors. - Created TestBackupFS_CreateNormalizesUncleanPath to check path normalization during file creation. - Introduced TestBackupFS_OpenFileAvoidsDuplicateLstat to confirm Lstat calls are minimized when opening files. - Added TestBackupFS_RemoveAllReusesObservedMetadata to ensure metadata is reused during removal operations. - Implemented TestBackupFS_RemoveAllPreservesErrorsAndRollback to verify error handling during removal. - Created TestBackupFS_RenameOverwriteRollback to check rollback functionality during renaming. - Added TestBackupFS_RenameAvoidsDuplicateLstat to ensure efficient metadata handling during renaming. - Implemented TestBackupFS_SymlinkReusesResolvedMetadata to confirm symlink creation reuses metadata. - Added TestBackupFS_MkdirReusesResolvedMetadata to ensure directory creation reuses metadata. - Implemented TestBackupFS_ChmodAvoidsDuplicateLstat and TestBackupFS_ChownAvoidsDuplicateLstat to minimize Lstat calls during permission changes. - Created TestBackupFS_ChtimesAvoidsDuplicateLstat to ensure efficient handling of modification times. - Added utility type lstatCountingFS to count Lstat calls for testing purposes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.