Last active
January 29, 2024 18:27
-
-
Save dhcgn/6680391391e153bd4079f1db6bc19227 to your computer and use it in GitHub Desktop.
This file contains 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
Round 0 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 1 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 2 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 3 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 4 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 5 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 6 | |
Testing Proton... | |
New-Object: test_cloud_strorage.ps1:40:14 | |
Line | | |
40 | … $f = new-object System.IO.FileStream $filename , Create, ReadW … | |
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
| Exception calling ".ctor" with "3" argument(s): "The process cannot access the file 'C:\Users\______\Proton Drive\______\My files\testing\test.bin' | |
| because it is being used by another process." | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 7 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 8 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... | |
Round 9 | |
Testing Proton... | |
Testing Google Drive... | |
Testing OneDrive... | |
Testing Mega... |
This file contains 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
$tests = @( | |
@{ | |
n = "Proton" | |
f = "C:\Users\*\Proton Drive\*\My files\testing\test.bin" | |
}, | |
@{ | |
n = "Google Drive" | |
f = "G:\*\testing\test.bin" | |
}, | |
@{ | |
n = "OneDrive" | |
f = "C:\Users\*\OneDrive\testing\test.bin" | |
}, | |
@{ | |
n = "Mega" | |
f = "C:\Users\*\Mega\testing\test.bin" | |
} | |
) | |
function createtestdata { | |
$result = "" | |
for ($i = 0; $i -lt 1024 * 10; $i++) { | |
$result += (New-Guid).ToString() | |
} | |
$result = [System.Text.Encoding]::UTF8.GetBytes($result) | |
return $result | |
} | |
for ($i = 0; $i -lt 10; $i++) { | |
Write-Host "Round $i" | |
$testdate = createtestdata | |
foreach ($test in $tests) { | |
Write-Host " Testing $($test.n)..." | |
$filename = (Get-ChildItem $test.f).FullName | |
$f = new-object System.IO.FileStream $filename , Create, ReadWrite | |
if(-not $?) { | |
continue | |
} | |
$f.Write($testdate, 0, $testdate.Length) | |
$f.Close() | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment