Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add initial FileVersionInfo support #703

Merged
merged 1 commit into from
Jan 9, 2025

Conversation

vbreuss
Copy link
Member

@vbreuss vbreuss commented Jan 9, 2025

Support for FileVersionInfo was added in TestableIO/System.IO.Abstractions#1177. Add basic support for the updated interfaces.
It is not yet possible to influence the mocked IFileVersionInfo in any way...

@vbreuss vbreuss added the enhancement New feature or request label Jan 9, 2025
@vbreuss vbreuss self-assigned this Jan 9, 2025
@vbreuss vbreuss force-pushed the topic/add-fileversioninfo-support branch from 586a330 to 5724ae1 Compare January 9, 2025 16:54
@vbreuss vbreuss enabled auto-merge (squash) January 9, 2025 16:55
Copy link

github-actions bot commented Jan 9, 2025

👽 Mutation Results

Mutation testing badge

Testably.Abstractions.Testing

Details
File Score Killed Survived Timeout No Coverage Ignored Compile Errors Total Detected Total Undetected Total Mutants
FileSystem/FileVersionInfoFactoryMock.cs 100.00% 2 0 0 0 0 0 2 0 2
FileSystem/FileVersionInfoMock.cs 0.00% 0 0 0 28 19 0 0 28 47
MockFileSystem.cs 94.74% 18 0 0 1 4 0 18 1 23
Statistics/FileSystemStatistics.cs 100.00% 1 0 0 0 0 0 1 0 1

The final mutation score is 42.00%

Coverage Thresholds: high:80 low:60 break:0

!-- END Testably.Abstractions.Testing -->

Testably.Abstractions.AccessControl

Details
File Score Killed Survived Timeout No Coverage Ignored Compile Errors Total Detected Total Undetected Total Mutants

The final mutation score is NaN%

Coverage Thresholds: high:80 low:60 break:0

!-- END Testably.Abstractions.AccessControl -->

Testably.Abstractions.Compression

Details
File Score Killed Survived Timeout No Coverage Ignored Compile Errors Total Detected Total Undetected Total Mutants

The final mutation score is NaN%

Coverage Thresholds: high:80 low:60 break:0

!-- END Testably.Abstractions.Compression -->

Testably.Abstractions

Details
File Score Killed Survived Timeout No Coverage Ignored Compile Errors Total Detected Total Undetected Total Mutants
FileSystem\FileVersionInfoFactory.cs 0.00% 0 1 0 0 0 0 0 1 1
FileSystem\FileVersionInfoWrapper.cs 0.00% 0 0 0 3 1 0 0 3 4
RealFileSystem.cs 100.00% 1 0 0 0 0 0 1 0 1

The final mutation score is 20.00%

Coverage Thresholds: high:80 low:60 break:0

!-- END Testably.Abstractions -->

Copy link

sonarqubecloud bot commented Jan 9, 2025

Copy link

github-actions bot commented Jan 9, 2025

Test Results

   46 files  ±  0     46 suites  ±0   1m 42s ⏱️ -22s
3 193 tests + 35  3 153 ✅ + 35   40 💤 ±0  0 ❌ ±0 
9 026 runs  +279  8 821 ✅ +279  205 💤 ±0  0 ❌ ±0 

Results for commit 5724ae1. ± Comparison against base commit 5ab1829.

This pull request removes 2376 and adds 2411 tests. Note that renamed tests count towards both.
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [169, 109, 165])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [207, 239, 65])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [236, 191, 90])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [32, 89, 64])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [52, 158, 182])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [57, 223, 82])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [62, 69, 25])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [73, 95, 234])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [97, 251, 119])
Testably.Abstractions.Testing.Tests.FileSystem.ChangeDescriptionTests ‑ ToString_ShouldIncludeChangeType(changeType: Created, fileSystemType: Directory, notifyFilters: FileName, path: "path2d0324f8-3763-4529-8656-6d6275971791")
…
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [102, 132, 196])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [102, 218, 180])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [129, 226, 173])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [181, 126, 54])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [186, 110, 217])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [37, 80, 20])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [50, 158, 40])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [87, 206, 184])
Testably.Abstractions.Compression.Tests.Internal.ZipUtilitiesTests ‑ ExtractRelativeToDirectory_FileWithTrailingSlash_ShouldThrowIOException(bytes: [89, 28, 11])
Testably.Abstractions.Parity.Tests.Net6ParityTests ‑ IFileVersionInfoAndIFileVersionInfoFactory_EnsureParityWith_FileVersionInfo
…
This pull request removes 39 skipped tests and adds 39 skipped tests. Note that renamed tests count towards both.
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ GetUnixFileMode_SafeFileHandle_ShouldThrowPlatformNotSupportedExceptionOnWindows(path: "path37736191-4cb5-462e-93b4-3ff36e70961a")
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ GetUnixFileMode_SafeFileHandle_ShouldThrowPlatformNotSupportedExceptionOnWindows(path: "pathb7a411b4-ded3-468f-84cf-c322e04c6c79")
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ GetUnixFileMode_SafeFileHandle_ShouldThrowPlatformNotSupportedExceptionOnWindows(path: "pathd3da26dd-430d-4246-909d-834fccbe5667")
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ GetUnixFileMode_SafeFileHandle_ShouldThrowPlatformNotSupportedExceptionOnWindows(path: "pathfe9a38a9-3142-4c02-a6aa-fcda77748d14")
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ SetUnixFileMode_SafeFileHandle_ShouldUpdateValue(path: "path79e2d238-636e-4267-b9f9-3be11ca4a978", mode: None)
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ SetUnixFileMode_SafeFileHandle_ShouldUpdateValue(path: "pathffb9d898-31e5-4a40-a333-56c4783f4af6", mode: None)
Testably.Abstractions.Testing.Tests.FileSystem.FileSystemWatcherMockTests ‑ InternalBufferSize_ShouldResetQueue(path1: "path11fb1f5e5-6e85-4660-9c9b-ccb1ec9b4393", path2: "path2c94cabc9-f6a1-4b5f-8838-cf3eb072e6e0")
Testably.Abstractions.Testing.Tests.FileSystem.FileSystemWatcherMockTests ‑ InternalBufferSize_ShouldResetQueue(path1: "path146877517-37c6-4028-8f45-e47f6e74d92e", path2: "path2b1e4170b-e2ae-43d2-9a82-63b5d6f541b6")
Testably.Abstractions.Testing.Tests.FileSystem.FileSystemWatcherMockTests ‑ InternalBufferSize_ShouldResetQueue(path1: "path18848ee86-d4b3-44b8-a8ac-3b1463eac847", path2: "path289a3bb6a-0d91-42f5-8e62-a43dc992e829")
Testably.Abstractions.Testing.Tests.FileSystem.FileSystemWatcherMockTests ‑ InternalBufferSize_ShouldResetQueue(path1: "path1c90cd069-20da-4804-bfb4-0ced394d4df5", path2: "path2a24166fe-b02a-4936-90ee-869747f85340")
…
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ GetUnixFileMode_SafeFileHandle_ShouldThrowPlatformNotSupportedExceptionOnWindows(path: "path78b70989-3672-4da9-b3bf-be047ed23aed")
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ GetUnixFileMode_SafeFileHandle_ShouldThrowPlatformNotSupportedExceptionOnWindows(path: "pathe0d102db-84c1-456f-bbb2-f8f19620f5d5")
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ GetUnixFileMode_SafeFileHandle_ShouldThrowPlatformNotSupportedExceptionOnWindows(path: "pathecc6dbea-168f-4d52-877f-70a869857d0a")
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ GetUnixFileMode_SafeFileHandle_ShouldThrowPlatformNotSupportedExceptionOnWindows(path: "pathfee1094b-b37a-4cad-9bd4-33759c85b60c")
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ SetUnixFileMode_SafeFileHandle_ShouldUpdateValue(path: "path2e6c57a8-658b-4913-86f0-c641803e1657", mode: None)
Testably.Abstractions.Testing.Tests.FileSystem.FileMockTests ‑ SetUnixFileMode_SafeFileHandle_ShouldUpdateValue(path: "path40dc5d74-f06b-4d72-9f5c-22f82560faaf", mode: None)
Testably.Abstractions.Testing.Tests.FileSystem.FileSystemWatcherMockTests ‑ InternalBufferSize_ShouldResetQueue(path1: "path1203343c9-a870-4fbf-8088-0954a426cb97", path2: "path2a51ace50-391a-4571-a803-0803ed8cd51b")
Testably.Abstractions.Testing.Tests.FileSystem.FileSystemWatcherMockTests ‑ InternalBufferSize_ShouldResetQueue(path1: "path141d56ae6-3edb-4218-a1c0-818e151717cf", path2: "path26412fd09-c3af-4ed0-9b6e-48ca8b00065e")
Testably.Abstractions.Testing.Tests.FileSystem.FileSystemWatcherMockTests ‑ InternalBufferSize_ShouldResetQueue(path1: "path14ea7716d-e755-4fa7-af88-26ccf30b4aff", path2: "path25bd6dcf7-1654-4429-8c10-409dac3bb6b3")
Testably.Abstractions.Testing.Tests.FileSystem.FileSystemWatcherMockTests ‑ InternalBufferSize_ShouldResetQueue(path1: "path1755820ce-2c93-4b55-b054-249fb432e3ee", path2: "path27c19e0fa-3448-4ba0-a04f-e29058d9dece")
…

@vbreuss vbreuss merged commit 8959969 into main Jan 9, 2025
14 checks passed
@vbreuss vbreuss deleted the topic/add-fileversioninfo-support branch January 9, 2025 17:11
Copy link

github-actions bot commented Feb 1, 2025

This is addressed in release v4.0.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request state: released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant