Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/SDKs/HDInsight/AzSdk.RP.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!--This file and it's contents are updated at build time moving or editing might result in build failure. Take due deligence while editing this file-->
<PropertyGroup>
<AzureApiTag>HDInsight_2015-03-01-preview;</AzureApiTag>
<AzureApiTag>HDInsight_2018-06-01-preview;</AzureApiTag>
<PackageTags>$(PackageTags);$(CommonTags);$(AzureApiTag);</PackageTags>
</PropertyGroup>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public void TestHttpExtended()
ValidateHttpSettings(httpSettings, createParams.UserName, createParams.Password);

string newPassword = "NewPassword1!";
client.Configurations.UpdateHTTPSettings(rgName, clusterName, ConfigurationKey.Gateway,
client.Configurations.Update(rgName, clusterName, ConfigurationKey.Gateway,
ConfigurationsConverter.Convert(new HttpConnectivitySettings
{
EnabledCredential = "true",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,28 +24,6 @@ namespace Management.HDInsight.Tests
[Collection("ScenarioTests")]
public class LocationsTests
{
[Fact]
public void TestGetCapabilities()
{
string suiteName = GetType().FullName;
string testName = "TestGetCapabilities";

using (MockContext context = MockContext.Start(suiteName, testName))
{
var handler = new RecordedDelegatingHandler { StatusCodeToReturn = HttpStatusCode.OK };
var client = HDInsightManagementTestUtilities.GetHDInsightManagementClient(context, handler);

CapabilitiesResult capabilities = client.Locations.GetCapabilities(HDInsightManagementTestUtilities.DefaultLocation);
Assert.NotNull(capabilities);
Assert.NotNull(capabilities.Features);
Assert.NotNull(capabilities.Quota);
Assert.NotNull(capabilities.Regions);
Assert.NotNull(capabilities.Versions);
Assert.NotNull(capabilities.VmSizeFilters);
Assert.NotNull(capabilities.VmSizes);
}
}

[Fact]
public void TestGetUsages()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ public class OMSTests
{
private const string WorkspaceId = "1d364e89-bb71-4503-aa3d-a23535aea7bd";
private const string PrimaryKey = "";



[Fact]
public void TestOMSOnRunningCluster()
{
Expand All @@ -44,13 +45,13 @@ public void TestOMSOnRunningCluster()
PrimaryKey = PrimaryKey
};

client.Extension.EnableMonitoring(rgName, clusterName, request);
ClusterMonitoringResponse monitoringStatus = client.Extension.GetMonitoringStatus(rgName, clusterName);
client.Extensions.EnableMonitoring(rgName, clusterName, request);
ClusterMonitoringResponse monitoringStatus = client.Extensions.GetMonitoringStatus(rgName, clusterName);
Assert.True(monitoringStatus.ClusterMonitoringEnabled);
Assert.Equal(monitoringStatus.WorkspaceId, WorkspaceId);

client.Extension.DisableMonitoring(rgName, clusterName);
monitoringStatus = client.Extension.GetMonitoringStatus(rgName, clusterName);
client.Extensions.DisableMonitoring(rgName, clusterName);
monitoringStatus = client.Extensions.GetMonitoringStatus(rgName, clusterName);
Assert.False(monitoringStatus.ClusterMonitoringEnabled);
Assert.Null(monitoringStatus.WorkspaceId);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public void TestScriptActionsOnRunningCluster()
client.Clusters.ExecuteScriptActions(rgName, clusterName, scriptActionParams, true);

//List script actions and validate script is persisted.
IPage<RuntimeScriptActionDetail> scriptActionsList = client.ScriptActions.ListPersistedScripts(rgName, clusterName);
IPage<RuntimeScriptActionDetail> scriptActionsList = client.ScriptActions.ListByCluster(rgName, clusterName);
Assert.Single(scriptActionsList);
RuntimeScriptActionDetail scriptAction = scriptActionsList.First();
Assert.Equal(scriptActionParams[0].Name, scriptAction.Name);
Expand All @@ -65,11 +65,11 @@ public void TestScriptActionsOnRunningCluster()
client.ScriptActions.Delete(rgName, clusterName, scriptName);

//List script actions and validate script is deleted.
scriptActionsList = client.ScriptActions.ListPersistedScripts(rgName, clusterName);
scriptActionsList = client.ScriptActions.ListByCluster(rgName, clusterName);
Assert.Empty(scriptActionsList);

//List script action history and validate script appears there.
IPage<RuntimeScriptActionDetail> listHistoryResponse = client.ScriptExecutionHistory.List(rgName, clusterName);
IPage<RuntimeScriptActionDetail> listHistoryResponse = client.ScriptExecutionHistory.ListByCluster(rgName, clusterName);
Assert.Single(listHistoryResponse);
scriptAction = listHistoryResponse.First();
Assert.Equal(1, scriptAction.ExecutionSummary.Count);
Expand All @@ -87,7 +87,7 @@ public void TestScriptActionsOnRunningCluster()
client.Clusters.ExecuteScriptActions(rgName, clusterName, scriptActionParams, false);

//List script action history and validate the new script also appears.
listHistoryResponse = client.ScriptExecutionHistory.List(rgName, clusterName);
listHistoryResponse = client.ScriptExecutionHistory.ListByCluster(rgName, clusterName);
Assert.Equal(2, listHistoryResponse.Count());
scriptAction = listHistoryResponse.FirstOrDefault(a => a.Name.Equals(scriptActionParams[0].Name, StringComparison.OrdinalIgnoreCase));
Assert.NotNull(scriptAction);
Expand All @@ -106,7 +106,7 @@ public void TestScriptActionsOnRunningCluster()
CloudException ex = Assert.Throws<CloudException>(() => client.Clusters.ExecuteScriptActions(rgName, clusterName, failingScriptActionParams, true));

//List script action list and validate the promoted script is the only one there.
scriptActionsList = client.ScriptActions.ListPersistedScripts(rgName, clusterName);
scriptActionsList = client.ScriptActions.ListByCluster(rgName, clusterName);
Assert.Single(scriptActionsList);
Assert.Equal(1, scriptAction.ExecutionSummary.Count);
Assert.Equal(scriptActionParams[0].Name, scriptAction.Name);
Expand All @@ -115,7 +115,7 @@ public void TestScriptActionsOnRunningCluster()
Assert.Equal("Succeeded", scriptAction.Status);

//List script action history and validate all three scripts are there.
listHistoryResponse = client.ScriptExecutionHistory.List(rgName, clusterName);
listHistoryResponse = client.ScriptExecutionHistory.ListByCluster(rgName, clusterName);
Assert.Equal(3, listHistoryResponse.Count());
Assert.Equal(2, listHistoryResponse.Count(a => a.Status == "Succeeded"));
Assert.Equal(1, listHistoryResponse.Count(a => a.Status == "Failed"));
Expand Down
Loading