Skip to content

Commit

Permalink
fix storage and eventhubs tests (#277)
Browse files Browse the repository at this point in the history
  • Loading branch information
cxznmhdcxz authored Apr 24, 2020
1 parent cf57573 commit 283dde1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions eventhubs/eventhubs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import (
)

const (
nsName = "ehtest-04-ns"
hubName = "ehtest-04-hub"
nsName = "ehtest04ns"
hubName = "ehtest04hub"

// for storage.LeaserCheckpointer
storageAccountName = "ehtest0001storage"
Expand Down
6 changes: 3 additions & 3 deletions storage/account_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,11 +86,11 @@ func Example_storageAccountOperations() {
}
util.PrintAndLog("get storage account keys")

_, err = RegenerateAccountKey(ctx, accountName, groupName, 0)
_, err = RegenerateAccountKey(ctx, accountName, groupName, 1)
if err != nil {
util.LogAndPanic(err)
}
util.PrintAndLog("regenerated first storage account key")
util.PrintAndLog("regenerated second storage account key")

_, err = ListUsage(ctx)
if err != nil {
Expand All @@ -107,6 +107,6 @@ func Example_storageAccountOperations() {
// listed storage accounts in resource group
// listed storage accounts in subscription
// get storage account keys
// regenerated first storage account key
// regenerated second storage account key
// listed usage
}
2 changes: 1 addition & 1 deletion storage/pageblob.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ func ClearPage(ctx context.Context, accountName, accountGroupName, containerName

_, err := b.ClearPages(ctx,
int64(pageNumber*azblob.PageBlobPageBytes),
int64((pageNumber+1)*azblob.PageBlobPageBytes-1),
int64(azblob.PageBlobPageBytes),
azblob.PageBlobAccessConditions{},
)
return err
Expand Down

0 comments on commit 283dde1

Please sign in to comment.