@@ -128,6 +128,50 @@ if ($Triplet -eq 'x64-windows-release') {
128128 $tripletArg = " --triplet=$Triplet "
129129}
130130
131+ # Test uploads with azcopy
132+ # Using portable binaries from
133+ # https://learn.microsoft.com/en-us/azure/storage/common/storage-use-azcopy-v10?tabs=dnf#download-the-azcopy-portable-binary
134+ if ($Triplet -eq ' x64-windows' )
135+ {
136+ $local_name = ' azcopy_windows_amd64_10.29.0'
137+ & $vcpkgExe x- download " $local_name .zip" " --url=https://aka.ms/downloadazcopy-v10-windows" " --sha512=fa2db4d722467eb0daebeddab20625198bbe7cd3102ac0fcec42a1b9f5f633e3d56cf4a02b2396c6ff3459eb291f5bfd5865cc97d4d731b6d05d0db1683c8a57" @cachingArgs
138+ Expand-Archive - Path " $local_name .zip" - Destination azcopy
139+ $env: PATH += " ;$PWD \azcopy\$local_name "
140+ }
141+ elseif ($Triplet -eq ' x64-linux' )
142+ {
143+ $local_name = ' azcopy_linux_amd64_10.29.0'
144+ & $vcpkgExe x- download " $local_name .tgz" " --url=https://aka.ms/downloadazcopy-v10-linux" " --sha512=c5f21fdf57066f9b4c17deb0b3649cb901863d8c6619f1a010abfde80ff7fdadf7ea9483bfa3820ae833e7953558294215b3a413b5efff75967fb368dcb1426a" @cachingArgs
145+ & tar xvzf " $local_name .tgz"
146+ $env: PATH += " :$PWD /$local_name "
147+ }
148+ & azcopy -- version
149+ $lastLastExitCode = $LASTEXITCODE
150+ if ($lastLastExitCode -ne 0 )
151+ {
152+ Write-Error ' Cannot run azcopy.'
153+ exit $lastLastExitCode
154+ }
155+ $env: AZCOPY_LOG_LOCATION = Join-Path $ArtifactStagingDirectory ' azcopy-logs'
156+ # Vary ABI hash
157+ Get-Date | Out-File " scripts/manual-tests/azcopy/test-upload-artifacts/mutable"
158+ # 3 GB < single max write (5 GB) < 6 GB, in files of 1.5 GB random data
159+ $data = New-Object byte[] 1.5 GB
160+ (New-Object System.Random).NextBytes($data )
161+ [System.IO.File ]::WriteAllBytes(" scripts/manual-tests/azcopy/core-1.dat" , $data )
162+ (New-Object System.Random).NextBytes($data )
163+ [System.IO.File ]::WriteAllBytes(" scripts/manual-tests/azcopy/core-2.dat" , $data )
164+ (New-Object System.Random).NextBytes($data )
165+ [System.IO.File ]::WriteAllBytes(" scripts/manual-tests/azcopy/large-1.dat" , $data )
166+ (New-Object System.Random).NextBytes($data )
167+ [System.IO.File ]::WriteAllBytes(" scripts/manual-tests/azcopy/large-2.dat" , $data )
168+ & $vcpkgExe x- test-features test-upload - artifacts -- overlay- ports= scripts/ manual- tests/ azcopy $tripletArg $failureLogsArg $ciBaselineArg $failingAbiLogArg $ciFeatureBaselineArg @commonArgs @cachingArgs
169+ if ($LASTEXITCODE -eq 0 )
170+ {
171+ & $vcpkgExe x- test-features -- only- binarycaching test-upload - artifacts -- overlay- ports= scripts/ manual- tests/ azcopy $tripletArg $failureLogsArg $ciBaselineArg $failingAbiLogArg $ciFeatureBaselineArg @commonArgs @cachingArgs
172+ }
173+ exit $LASTEXITCODE
174+
131175$failureLogs = Join-Path $ArtifactStagingDirectory ' failure-logs'
132176$failureLogsArg = " --failure-logs=$failureLogs "
133177$knownFailuresFromArgs = @ ()
0 commit comments