コード例 #1
0
        /// <summary>
        /// Returns appropriate AzureDataLakeStoreInfo based on test-mode.
        /// </summary>
        /// <returns></returns>
        private static StorageInfo GetDefaultAzureDataLakeStoreInfo()
        {
            bool   recordMode         = HDInsightManagementTestUtilities.IsRecordMode();
            string ADLClusterRootPath = "/Clusters/SDK";

            return(recordMode
               ? new AzureDataLakeStoreInfo(ADLDefaultStorageAccountName, ADLClusterRootPath)
               : new AzureDataLakeStoreInfo("tmp.azuredatalakestore.net", ADLClusterRootPath));
        }
コード例 #2
0
        /// <summary>
        /// Returns appropriate AzureStorageInfo based on test-mode.
        /// </summary>
        /// <returns></returns>
        private static StorageInfo GetDefaultAzureStorageInfo(bool specifyDefaultContainer = true)
        {
            bool recordMode = HDInsightManagementTestUtilities.IsRecordMode();

            if (recordMode)
            {
                return((specifyDefaultContainer)
                    ? new AzureStorageInfo(StorageAccountName, StorageAccountKey, DefaultContainer)
                    : new AzureStorageInfo(StorageAccountName, StorageAccountKey));
            }
            else
            {
                string testStorageAccountName = "tmp.blob.core.windows.net";
                string testStorageAccountKey  = "teststorageaccountkey";
                string testContainer          = "testdefaultcontainer";

                return((specifyDefaultContainer)
                    ? new AzureStorageInfo(testStorageAccountName, testStorageAccountKey, testContainer)
                    : new AzureStorageInfo(testStorageAccountName, testStorageAccountKey));
            }
        }