[Mono-dev] Fixing bug 39915 (DriveInfo.VolumeLabel does not return Volume Label under Windows)
monoman at gmail.com
Fri Apr 7 13:48:56 UTC 2017
You could start a process (console) and capture the standard output, and in
it call 'dir'. It is convoluted but I do it frequently for testing
interactions between multiple processes.
On Fri, Apr 7, 2017 at 10:28 AM, HKakuschke <horst at kakuschke.de> wrote:
> as I recently also suffered from Bug 39915 under Windows OS, I would like
> fix that.
> Handling volume labels under Windows OS could be done via Windows API
> functions GetVolumeInformation() and SetVolumeLabel() respectively (like
> getting DriveInfo.TotalFreeSpace is handled via Windows API function
> But, I just don't have any idea how to write test cases for this:
> - to test the getter of DriveInfo.VolumeLabel one would need to know the
> volume labels of the drives of the test machine
> - to test the setter of DriveInfo.VolumeLabel one would have to alter the
> volume label of at least one of the drives of the test machine.
> Any suggestions or ideas?
> View this message in context: http://mono.1490590.n4.nabble.
> Sent from the Mono - Dev mailing list archive at Nabble.com.
> Mono-devel-list mailing list
> Mono-devel-list at lists.dot.net
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Mono-devel-list