dsccommunity / StorageDsc

DSC resource module is used to manage storage on Windows Servers.
https://dsccommunity.org
MIT License
69 stars 51 forks source link

MSFT_Disk: Implement workaround for maximum size discrepancy (fixes #181) #197

Closed nyanhp closed 4 years ago

nyanhp commented 5 years ago

Pull Request (PR) description

This PR introduces a workaround that fixes issue #181 where the reported maximum supported size of a partition would be approximately 1MB bigger than the actual size of the partition. As long as it is unclear why the New-Partition and Get-PartitionSupportedSize cmdlets report different data if neither Offset nor Alignment parameters are used, this workaround should remain in place.

If this is not the case, Test-TargetResource for a disk configured to use the remaining size will always return false and trigger an endless cycle of LCM runs.

This Pull Request (PR) fixes the following issues

Task list


This change is Reviewable

codecov-io commented 5 years ago

Codecov Report

Merging #197 into dev will increase coverage by <1%. The diff coverage is 100%.

Impacted file tree graph

@@         Coverage Diff         @@
##           dev   #197    +/-   ##
===================================
+ Coverage   94%    94%   +<1%     
===================================
  Files        8      8            
  Lines      889    891     +2     
===================================
+ Hits       837    839     +2     
  Misses      52     52
nyanhp commented 5 years ago

I have 0 ideas why the build suddenly fails. I did a rebase since the changelog was getting in the way of a merge. Will have a look

PlagueHO commented 5 years ago

Thanks @nyanhp - I'll get onto this review this weekend (finally will have some free time).

PlagueHO commented 5 years ago

Hi @nyanhp - are you still working on this one?

PlagueHO commented 4 years ago

Closing because replaced by #213