Skip to content

Commit

Permalink
Merge pull request Azure#40 from yifanz7/addtests
Browse files Browse the repository at this point in the history
update regression test scripts
  • Loading branch information
yifanz7 authored Aug 28, 2024
2 parents 6bab59c + ad40240 commit 9a2005a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/Storage/RegressionTests/dataplane.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ BeforeAll {
#$cred = New-Object System.Management.Automation.PSCredential ($globalNode.applicationId, $secpasswd)
#Add-AzAccount -ServicePrincipal -Tenant $globalNode.tenantId -SubscriptionId $globalNode.subscriptionId -Credential $cred

COnnect-AzAccount
# COnnect-AzAccount
$ctxoauth1 = New-AzStorageContext -StorageAccountName $storageAccountName
$ctxoauth2 = New-AzStorageContext -StorageAccountName $storageAccountName2

Expand Down
6 changes: 3 additions & 3 deletions src/Storage/RegressionTests/srp.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -945,7 +945,7 @@ Describe "Management plan test" {
Get-AzStorageAccount -ResourceGroupName $rgname -StorageAccountName $srcAccountName

Update-AzStorageBlobServiceProperty -ResourceGroupName $rgname -StorageAccountName $destAccountName -IsVersioningEnabled $false -EnableChangeFeed $true
Update-AzStorageBlobServiceProperty -ResourceGroupName $rgname -StorageAccountName $destAccountName -IsVersioningEnabled $true -EnableChangeFeed $true
Update-AzStorageBlobServiceProperty -ResourceGroupName $rgname -StorageAccountName $srctAccountName -IsVersioningEnabled $true -EnableChangeFeed $true
Get-AzStorageBlobServiceProperty -ResourceGroupName $rgname -StorageAccountName $destAccountName
Get-AzStorageBlobServiceProperty -ResourceGroupName $rgname -StorageAccountName $srcAccountName

Expand All @@ -960,9 +960,9 @@ Describe "Management plan test" {
$ctxsrc = (Get-AzStorageAccount -ResourceGroupName $rgname -StorageAccountName $srcAccountName).Context
$ctxdest = (Get-AzStorageAccount -ResourceGroupName $rgname -StorageAccountName $destAccountName).Context

Set-AzStorageBlobContent -Container src1 -File D:\TestBlob1 -Blob testors -Context $ctxsrc
Set-AzStorageBlobContent -Container src1 -File D:\TestBlob1 -Blob testors -Context $ctxsrc -Force

Set-AzStorageBlobContent -Container dest1 -File D:\TestBlob1 -Blob testors -Context $ctxdest
Set-AzStorageBlobContent -Container dest1 -File D:\TestBlob1 -Blob testors -Context $ctxdest -Force
}

# enable AllowCrossTenantReplication
Expand Down
4 changes: 2 additions & 2 deletions src/Storage/RegressionTests/utils.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ function Upload_Download_FileTree

function Upload_Download_BlobTree
{
param([Microsoft.WindowsAzure.Commands.Storage.AzureStorageContext]$context, [string]$rootFolder, [string]$blobType = "Block")
param([Microsoft.WindowsAzure.Commands.Storage.common.AzureStorageContext]$context, [string]$rootFolder, [string]$blobType = "Block")

$containerName = GetRandomContainerName

Expand Down Expand Up @@ -233,7 +233,7 @@ function ValidBlob

function uploadblob
{
param([Microsoft.WindowsAzure.Commands.Storage.AzureStorageContext]$context)
param([Microsoft.WindowsAzure.Commands.Storage.Common.AzureStorageContext]$context)

$b = Set-AzStorageBlobContent -Context $context -File $localSrcFile -Container $containerName_es -Blob block -BlobType Block -EncryptionScope $scopeName1 `
-Properties @{"ContentType" = "image/jpeg"} -Metadata @{"tag1" = "value1"; "tag2" = "value22" } -Force
Expand Down

0 comments on commit 9a2005a

Please sign in to comment.