From 4e38e8961e9cabca4c6886e4e5e5934fc4be43a0 Mon Sep 17 00:00:00 2001 From: JinmingHu Date: Wed, 2 Dec 2020 08:15:18 +0800 Subject: [PATCH] fix typo (#1045) --- .../azure-storage-blobs/test/blob_batch_client_test.cpp | 2 +- .../azure-storage-blobs/test/blob_container_client_test.cpp | 2 +- sdk/storage/azure-storage-blobs/test/blob_sas_test.cpp | 4 ++-- .../inc/azure/storage/common/account_sas_builder.hpp | 4 ++-- sdk/storage/azure-storage-common/src/account_sas_builder.cpp | 2 +- .../azure-storage-files-datalake/test/datalake_sas_test.cpp | 2 +- .../test/datalake_service_client_test.cpp | 2 +- .../azure-storage-files-shares/test/share_sas_test.cpp | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/sdk/storage/azure-storage-blobs/test/blob_batch_client_test.cpp b/sdk/storage/azure-storage-blobs/test/blob_batch_client_test.cpp index 8a8f08b7f..7734b84cd 100644 --- a/sdk/storage/azure-storage-blobs/test/blob_batch_client_test.cpp +++ b/sdk/storage/azure-storage-blobs/test/blob_batch_client_test.cpp @@ -23,7 +23,7 @@ namespace Azure { namespace Storage { namespace Test { TEST_F(BlobBatchClientTest, BatchSasAuth) { AccountSasBuilder accountSasBuilder; - accountSasBuilder.Protocol = SasProtocol::HttpsAndHtttp; + accountSasBuilder.Protocol = SasProtocol::HttpsAndHttp; accountSasBuilder.StartsOn = ToIso8601(std::chrono::system_clock::now() - std::chrono::minutes(5)); accountSasBuilder.ExpiresOn diff --git a/sdk/storage/azure-storage-blobs/test/blob_container_client_test.cpp b/sdk/storage/azure-storage-blobs/test/blob_container_client_test.cpp index eef4da05a..03c573177 100644 --- a/sdk/storage/azure-storage-blobs/test/blob_container_client_test.cpp +++ b/sdk/storage/azure-storage-blobs/test/blob_container_client_test.cpp @@ -40,7 +40,7 @@ namespace Azure { namespace Storage { namespace Test { std::string BlobContainerClientTest::GetSas() { Blobs::BlobSasBuilder sasBuilder; - sasBuilder.Protocol = SasProtocol::HttpsAndHtttp; + sasBuilder.Protocol = SasProtocol::HttpsAndHttp; sasBuilder.ExpiresOn = ToIso8601(std::chrono::system_clock::now() + std::chrono::hours(72)); sasBuilder.BlobContainerName = m_containerName; sasBuilder.Resource = Blobs::BlobSasResource::BlobContainer; diff --git a/sdk/storage/azure-storage-blobs/test/blob_sas_test.cpp b/sdk/storage/azure-storage-blobs/test/blob_sas_test.cpp index 6c5f2069a..51b36cdb0 100644 --- a/sdk/storage/azure-storage-blobs/test/blob_sas_test.cpp +++ b/sdk/storage/azure-storage-blobs/test/blob_sas_test.cpp @@ -9,7 +9,7 @@ namespace Azure { namespace Storage { namespace Test { TEST_F(BlobContainerClientTest, BlobSasTest) { AccountSasBuilder accountSasBuilder; - accountSasBuilder.Protocol = SasProtocol::HttpsAndHtttp; + accountSasBuilder.Protocol = SasProtocol::HttpsAndHttp; accountSasBuilder.StartsOn = ToIso8601(std::chrono::system_clock::now() - std::chrono::minutes(5)); accountSasBuilder.ExpiresOn @@ -19,7 +19,7 @@ namespace Azure { namespace Storage { namespace Test { std::string blobName = RandomString(); Blobs::BlobSasBuilder blobSasBuilder; - blobSasBuilder.Protocol = SasProtocol::HttpsAndHtttp; + blobSasBuilder.Protocol = SasProtocol::HttpsAndHttp; blobSasBuilder.StartsOn = ToIso8601(std::chrono::system_clock::now() - std::chrono::minutes(5)); blobSasBuilder.ExpiresOn = ToIso8601(std::chrono::system_clock::now() + std::chrono::minutes(60)); diff --git a/sdk/storage/azure-storage-common/inc/azure/storage/common/account_sas_builder.hpp b/sdk/storage/azure-storage-common/inc/azure/storage/common/account_sas_builder.hpp index c6a9a775e..1192625d7 100644 --- a/sdk/storage/azure-storage-common/inc/azure/storage/common/account_sas_builder.hpp +++ b/sdk/storage/azure-storage-common/inc/azure/storage/common/account_sas_builder.hpp @@ -20,7 +20,7 @@ namespace Azure { namespace Storage { /** * @brief Only requests issued over HTTPS or HTTP will be permitted. */ - HttpsAndHtttp, + HttpsAndHttp, /** * @brief Only requests issued over HTTPS will be permitted. @@ -30,7 +30,7 @@ namespace Azure { namespace Storage { inline std::string SasProtocolToString(SasProtocol protocol) { - return protocol == SasProtocol::HttpsAndHtttp ? "https,http" : "https"; + return protocol == SasProtocol::HttpsAndHttp ? "https,http" : "https"; } /** diff --git a/sdk/storage/azure-storage-common/src/account_sas_builder.cpp b/sdk/storage/azure-storage-common/src/account_sas_builder.cpp index a10a946ec..1bb216302 100644 --- a/sdk/storage/azure-storage-common/src/account_sas_builder.cpp +++ b/sdk/storage/azure-storage-common/src/account_sas_builder.cpp @@ -60,7 +60,7 @@ namespace Azure { namespace Storage { std::string AccountSasBuilder::GenerateSasToken(const StorageSharedKeyCredential& credential) { std::string protocol; - if (Protocol == SasProtocol::HttpsAndHtttp) + if (Protocol == SasProtocol::HttpsAndHttp) { protocol = "https,http"; } diff --git a/sdk/storage/azure-storage-files-datalake/test/datalake_sas_test.cpp b/sdk/storage/azure-storage-files-datalake/test/datalake_sas_test.cpp index 91c0dc9c7..dd7906994 100644 --- a/sdk/storage/azure-storage-files-datalake/test/datalake_sas_test.cpp +++ b/sdk/storage/azure-storage-files-datalake/test/datalake_sas_test.cpp @@ -13,7 +13,7 @@ namespace Azure { namespace Storage { namespace Test { std::string directory2Name = RandomString(); std::string fileName = RandomString(); Files::DataLake::DataLakeSasBuilder fileSasBuilder; - fileSasBuilder.Protocol = SasProtocol::HttpsAndHtttp; + fileSasBuilder.Protocol = SasProtocol::HttpsAndHttp; fileSasBuilder.StartsOn = ToIso8601(std::chrono::system_clock::now() - std::chrono::minutes(5)); fileSasBuilder.ExpiresOn = ToIso8601(std::chrono::system_clock::now() + std::chrono::minutes(60)); diff --git a/sdk/storage/azure-storage-files-datalake/test/datalake_service_client_test.cpp b/sdk/storage/azure-storage-files-datalake/test/datalake_service_client_test.cpp index 95cd79a77..1a5fe6cf5 100644 --- a/sdk/storage/azure-storage-files-datalake/test/datalake_service_client_test.cpp +++ b/sdk/storage/azure-storage-files-datalake/test/datalake_service_client_test.cpp @@ -142,7 +142,7 @@ namespace Azure { namespace Storage { namespace Test { auto keyCredential = Azure::Storage::Details::ParseConnectionString(AdlsGen2ConnectionString()).KeyCredential; AccountSasBuilder accountSasBuilder; - accountSasBuilder.Protocol = SasProtocol::HttpsAndHtttp; + accountSasBuilder.Protocol = SasProtocol::HttpsAndHttp; accountSasBuilder.StartsOn = ToIso8601(std::chrono::system_clock::now() - std::chrono::minutes(5)); accountSasBuilder.ExpiresOn diff --git a/sdk/storage/azure-storage-files-shares/test/share_sas_test.cpp b/sdk/storage/azure-storage-files-shares/test/share_sas_test.cpp index 543e2031b..51b237a63 100644 --- a/sdk/storage/azure-storage-files-shares/test/share_sas_test.cpp +++ b/sdk/storage/azure-storage-files-shares/test/share_sas_test.cpp @@ -11,7 +11,7 @@ namespace Azure { namespace Storage { namespace Test { { std::string fileName = RandomString(); Files::Shares::ShareSasBuilder fileSasBuilder; - fileSasBuilder.Protocol = SasProtocol::HttpsAndHtttp; + fileSasBuilder.Protocol = SasProtocol::HttpsAndHttp; fileSasBuilder.StartsOn = ToIso8601(std::chrono::system_clock::now() - std::chrono::minutes(5)); fileSasBuilder.ExpiresOn = ToIso8601(std::chrono::system_clock::now() + std::chrono::minutes(60));