Skip to content

Commit 005fdc9

Browse files
committed
Merge pull request #1434 from SiddharthChatrolaMs/dev
Added new cmdlets for Diagnostics
2 parents 6ea5e08 + a578263 commit 005fdc9

37 files changed

+3253
-1221
lines changed

ChangeLog.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
* Azure Redis Cache: new cmdlets for enabling and disabling diagnostics
2+
* Set-AzureRmRedisCacheDiagnostics
3+
* Remove-AzureRmRedisCacheDiagnostics
14
## 2015.12.14 version 1.0.2
25
* Azure Compute (ARM):
36
* Enable BGInfo extension by default

setup/azurecmdfiles.wxi

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1817,12 +1817,24 @@
18171817
<Component Id="cmpDB48760E05625FA4A872912DADB76AE8" Guid="*">
18181818
<File Id="fil60FDC0D18C9BF51BDE5B8D50240CC229" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.Azure.Common.NetFramework.dll" />
18191819
</Component>
1820+
<Component Id="cmpE542A66FF253AB7ECF153BC7F8617497" Guid="*">
1821+
<File Id="fil076A3639A8C23CB436A1A95F071AB968" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.Azure.Insights.dll" />
1822+
</Component>
18201823
<Component Id="cmp3A5E7F3EA44ACFDD84B8CE1D36DA80C7" Guid="*">
18211824
<File Id="fil9B815D18A217668B9C3F30A088551FEE" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.Azure.Management.Redis.dll" />
18221825
</Component>
18231826
<Component Id="cmpB77BD825E0EE360848A0E312174B8E79" Guid="*">
18241827
<File Id="filC946540561EFB51E32A9A78C9A4C4E4E" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.Azure.ResourceManager.dll" />
18251828
</Component>
1829+
<Component Id="cmpB1AB5620182396F5055594CB5B71DFF5" Guid="*">
1830+
<File Id="fil927418DCA437A44F331156F1B181B0CB" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.Data.Edm.dll" />
1831+
</Component>
1832+
<Component Id="cmpF3A6E2A588E2828B1141B2B4F2DEE2CA" Guid="*">
1833+
<File Id="fil6885A1C5198BBE4BE218B29F4AF8CD4F" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.Data.OData.dll" />
1834+
</Component>
1835+
<Component Id="cmpDFF1A711321C50653141E2AE4BB76806" Guid="*">
1836+
<File Id="filF25C5E7B600CD1857B7B71EF4B86B617" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.Data.Services.Client.dll" />
1837+
</Component>
18261838
<Component Id="cmpD5D6E28B9232D19A4D3FC543B56214DB" Guid="*">
18271839
<File Id="filA67517D2439E43C4974AAF323963F31C" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.IdentityModel.Clients.ActiveDirectory.dll" />
18281840
</Component>
@@ -1847,9 +1859,15 @@
18471859
<Component Id="cmpBF4F488538112494F0A0EC9CF8CCD0B4" Guid="*">
18481860
<File Id="fil3FED2453D2E82E73974E11458353961E" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.WindowsAzure.Commands.Common.dll" />
18491861
</Component>
1862+
<Component Id="cmpD9FF11D5CD2979DD0DA06D22A9CFC352" Guid="*">
1863+
<File Id="filBE19BD3615AFCF7906F6C714C2564D63" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.WindowsAzure.Configuration.dll" />
1864+
</Component>
18501865
<Component Id="cmpA3F0584F49B26E431792BDDA23CA5844" Guid="*">
18511866
<File Id="filE0B28C51A17B5758F64068F08B6EE7F7" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.WindowsAzure.Management.dll" />
18521867
</Component>
1868+
<Component Id="cmp5D9B9CA7570E8D2EB671AA2197A22A52" Guid="*">
1869+
<File Id="fil315EBA6955167FF42135413C69608424" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Microsoft.WindowsAzure.Storage.dll" />
1870+
</Component>
18531871
<Component Id="cmpA29B2E41943B2D8BB993F59ADA816E87" Guid="*">
18541872
<File Id="fil270FECD6ED1DADB4F9730F763969841A" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\Newtonsoft.Json.dll" />
18551873
</Component>
@@ -1859,6 +1877,9 @@
18591877
<Component Id="cmpC71AD037C10F73FFA59A6255D98190D4" Guid="*">
18601878
<File Id="filED0BBA70A2560C98E0554C93CEB81B0B" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\System.Net.Http.Primitives.dll" />
18611879
</Component>
1880+
<Component Id="cmp52C57B0899D353B0A0560BB9EE958B68" Guid="*">
1881+
<File Id="fil593DDDA285E20B8837098A7387A09B84" KeyPath="yes" Source="$(var.sourceDir)\ResourceManager\AzureResourceManager\AzureRM.RedisCache\System.Spatial.dll" />
1882+
</Component>
18621883
</Directory>
18631884
<Directory Id="dir5A96CDDC32336B058D325B4B67756080" Name="AzureRM.Resources">
18641885
<Component Id="cmp4DDC11D6580AB2CC03CADEDD62194BDA" Guid="*">
@@ -5376,8 +5397,12 @@
53765397
<ComponentRef Id="cmp90E147CA930F23090C5880CEF5A26B82" />
53775398
<ComponentRef Id="cmp805E82D161288ED9EE4AD5A6CDA1D594" />
53785399
<ComponentRef Id="cmpDB48760E05625FA4A872912DADB76AE8" />
5400+
<ComponentRef Id="cmpE542A66FF253AB7ECF153BC7F8617497" />
53795401
<ComponentRef Id="cmp3A5E7F3EA44ACFDD84B8CE1D36DA80C7" />
53805402
<ComponentRef Id="cmpB77BD825E0EE360848A0E312174B8E79" />
5403+
<ComponentRef Id="cmpB1AB5620182396F5055594CB5B71DFF5" />
5404+
<ComponentRef Id="cmpF3A6E2A588E2828B1141B2B4F2DEE2CA" />
5405+
<ComponentRef Id="cmpDFF1A711321C50653141E2AE4BB76806" />
53815406
<ComponentRef Id="cmpD5D6E28B9232D19A4D3FC543B56214DB" />
53825407
<ComponentRef Id="cmp6DCD11F46E1DCE998C423CD0BC09CD15" />
53835408
<ComponentRef Id="cmp97DCE18753534AD69AF7E7D8D9E44502" />
@@ -5386,10 +5411,13 @@
53865411
<ComponentRef Id="cmp1BF396A297DE4BB9EFCE53AA38D5EF41" />
53875412
<ComponentRef Id="cmpCD22DDF0DFFCD87EFE8CB3AEAD7B2D10" />
53885413
<ComponentRef Id="cmpBF4F488538112494F0A0EC9CF8CCD0B4" />
5414+
<ComponentRef Id="cmpD9FF11D5CD2979DD0DA06D22A9CFC352" />
53895415
<ComponentRef Id="cmpA3F0584F49B26E431792BDDA23CA5844" />
5416+
<ComponentRef Id="cmp5D9B9CA7570E8D2EB671AA2197A22A52" />
53905417
<ComponentRef Id="cmpA29B2E41943B2D8BB993F59ADA816E87" />
53915418
<ComponentRef Id="cmp4E9B33C40EDE71B61567265DDE41AA40" />
53925419
<ComponentRef Id="cmpC71AD037C10F73FFA59A6255D98190D4" />
5420+
<ComponentRef Id="cmp52C57B0899D353B0A0560BB9EE958B68" />
53935421
<ComponentRef Id="cmp4DDC11D6580AB2CC03CADEDD62194BDA" />
53945422
<ComponentRef Id="cmpE3F8AFED4B05B18FC4A7CAB87B1CB417" />
53955423
<ComponentRef Id="cmpB3DCE82FE478526DDF1700692DBA9623" />

src/ResourceManager/RedisCache/AzureRM.RedisCache.psd1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
@{
1010

1111
# Version number of this module.
12-
ModuleVersion = '1.0.2'
12+
ModuleVersion = '1.1.0'
1313

1414
# ID used to uniquely identify this module
1515
GUID = '820628d7-6938-488a-8760-43373a5ffce6'
@@ -45,7 +45,7 @@ CLRVersion='4.0'
4545
ProcessorArchitecture = 'None'
4646

4747
# Modules that must be imported into the global environment prior to importing this module
48-
RequiredModules = @( @{ ModuleName = 'AzureRM.Profile'; ModuleVersion = '1.0.2'})
48+
RequiredModules = @( @{ ModuleName = 'AzureRM.Profile'; ModuleVersion = '1.1.0'})
4949

5050
# Assemblies that must be loaded prior to importing this module
5151
RequiredAssemblies = @()

src/ResourceManager/RedisCache/Commands.RedisCache.Test/Commands.RedisCache.Test.csproj

Lines changed: 35 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,12 @@
5656
<Reference Include="Microsoft.Azure.Common.NetFramework">
5757
<HintPath>..\..\..\packages\Microsoft.Azure.Common.2.1.0\lib\net45\Microsoft.Azure.Common.NetFramework.dll</HintPath>
5858
</Reference>
59-
<Reference Include="Microsoft.Azure.Management.Redis, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
60-
<HintPath>..\..\..\packages\Microsoft.Azure.Management.Redis.1.1.0-preview\lib\net40\Microsoft.Azure.Management.Redis.dll</HintPath>
59+
<Reference Include="Microsoft.Azure.Insights, Version=0.9.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
60+
<HintPath>..\..\..\packages\Microsoft.Azure.Insights.0.9.1-preview\lib\net45\Microsoft.Azure.Insights.dll</HintPath>
61+
<Private>True</Private>
62+
</Reference>
63+
<Reference Include="Microsoft.Azure.Management.Redis, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
64+
<HintPath>..\..\..\packages\Microsoft.Azure.Management.Redis.1.2.0-preview\lib\net40\Microsoft.Azure.Management.Redis.dll</HintPath>
6165
<Private>True</Private>
6266
</Reference>
6367
<Reference Include="Microsoft.Azure.ResourceManager, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
@@ -72,6 +76,18 @@
7276
<SpecificVersion>False</SpecificVersion>
7377
<HintPath>..\..\..\packages\Microsoft.Azure.Test.HttpRecorder.1.0.5799.28345-prerelease\lib\net45\Microsoft.Azure.Test.HttpRecorder.dll</HintPath>
7478
</Reference>
79+
<Reference Include="Microsoft.Data.Edm, Version=5.6.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
80+
<HintPath>..\..\..\packages\Microsoft.Data.Edm.5.6.0\lib\net40\Microsoft.Data.Edm.dll</HintPath>
81+
<Private>True</Private>
82+
</Reference>
83+
<Reference Include="Microsoft.Data.OData, Version=5.6.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
84+
<HintPath>..\..\..\packages\Microsoft.Data.OData.5.6.0\lib\net40\Microsoft.Data.OData.dll</HintPath>
85+
<Private>True</Private>
86+
</Reference>
87+
<Reference Include="Microsoft.Data.Services.Client, Version=5.6.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
88+
<HintPath>..\..\..\packages\Microsoft.Data.Services.Client.5.6.0\lib\net40\Microsoft.Data.Services.Client.dll</HintPath>
89+
<Private>True</Private>
90+
</Reference>
7591
<Reference Include="Microsoft.IdentityModel.Clients.ActiveDirectory">
7692
<SpecificVersion>False</SpecificVersion>
7793
<HintPath>..\..\..\packages\Microsoft.IdentityModel.Clients.ActiveDirectory.2.18.206251556\lib\net45\Microsoft.IdentityModel.Clients.ActiveDirectory.dll</HintPath>
@@ -100,9 +116,17 @@
100116
<SpecificVersion>False</SpecificVersion>
101117
<HintPath>..\..\..\packages\Microsoft.Bcl.Async.1.0.168\lib\net40\Microsoft.Threading.Tasks.Extensions.Desktop.dll</HintPath>
102118
</Reference>
119+
<Reference Include="Microsoft.WindowsAzure.Configuration, Version=1.8.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
120+
<HintPath>..\..\..\packages\Microsoft.WindowsAzure.ConfigurationManager.1.8.0.0\lib\net35-full\Microsoft.WindowsAzure.Configuration.dll</HintPath>
121+
<Private>True</Private>
122+
</Reference>
103123
<Reference Include="Microsoft.WindowsAzure.Management">
104124
<HintPath>..\..\..\packages\Microsoft.WindowsAzure.Management.4.1.1\lib\net40\Microsoft.WindowsAzure.Management.dll</HintPath>
105125
</Reference>
126+
<Reference Include="Microsoft.WindowsAzure.Storage, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
127+
<HintPath>..\..\..\packages\WindowsAzure.Storage.4.0.0\lib\net40\Microsoft.WindowsAzure.Storage.dll</HintPath>
128+
<Private>True</Private>
129+
</Reference>
106130
<Reference Include="Moq, Version=4.2.1402.2112, Culture=neutral, PublicKeyToken=69f491c39445e920, processorArchitecture=MSIL">
107131
<SpecificVersion>False</SpecificVersion>
108132
<HintPath>..\..\..\packages\Moq.4.2.1402.2112\lib\net40\Moq.dll</HintPath>
@@ -128,6 +152,10 @@
128152
<HintPath>..\..\..\packages\Microsoft.Net.Http.2.2.28\lib\net45\System.Net.Http.Primitives.dll</HintPath>
129153
</Reference>
130154
<Reference Include="System.Net.Http.WebRequest" />
155+
<Reference Include="System.Spatial, Version=5.6.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
156+
<HintPath>..\..\..\packages\System.Spatial.5.6.0\lib\net40\System.Spatial.dll</HintPath>
157+
<Private>True</Private>
158+
</Reference>
131159
<Reference Include="System.Xml.Linq" />
132160
<Reference Include="System.Data.DataSetExtensions" />
133161
<Reference Include="Microsoft.CSharp" />
@@ -171,19 +199,19 @@
171199
<None Include="ScenarioTests\RedisCacheTests.ps1">
172200
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
173201
</None>
174-
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestCreateExistingRedisCacheTest.json">
175-
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
176-
</None>
177202
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestRedisCache.json">
178203
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
179204
</None>
180205
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestRedisCacheClustering.json">
181206
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
182207
</None>
183-
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestRedisCacheParameterDeprecated.json">
208+
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestRedisCachePipeline.json">
184209
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
185210
</None>
186-
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestRedisCachePipeline.json">
211+
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestRemoveAzureRedisCacheDiagnostics.json">
212+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
213+
</None>
214+
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestSetAzureRedisCacheDiagnostics.json">
187215
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
188216
</None>
189217
<None Include="SessionRecords\Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests.RedisCacheTests\TestSetNonExistingRedisCacheTest.json">

src/ResourceManager/RedisCache/Commands.RedisCache.Test/ScenarioTests/RedisCacheTests.cs

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,5 +61,19 @@ public void TestRedisCacheClustering()
6161
{
6262
RunPowerShellTest("Test-RedisCacheClustering");
6363
}
64+
65+
[Fact]
66+
[Trait(Category.AcceptanceType, Category.CheckIn)]
67+
public void TestSetAzureRedisCacheDiagnostics()
68+
{
69+
RunPowerShellTest("Test-SetAzureRedisCacheDiagnostics");
70+
}
71+
72+
[Fact]
73+
[Trait(Category.AcceptanceType, Category.CheckIn)]
74+
public void TestRemoveAzureRedisCacheDiagnostics()
75+
{
76+
RunPowerShellTest("Test-RemoveAzureRedisCacheDiagnostics");
77+
}
6478
}
6579
}

src/ResourceManager/RedisCache/Commands.RedisCache.Test/ScenarioTests/RedisCacheTests.ps1

Lines changed: 35 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ function Test-RedisCache
66
{
77
# Setup
88
# resource group should exists
9-
$resourceGroupName = "MyResourceGroup"
9+
$resourceGroupName = "SunnyAAPT6"
1010
$cacheName = "powershelltest"
1111
$location = "North Central US"
1212

@@ -145,7 +145,7 @@ function Test-SetNonExistingRedisCacheTest
145145
{
146146
# Setup
147147
# resource group should exists
148-
$resourceGroupName = "MyResourceGroup"
148+
$resourceGroupName = "SunnyAAPT6"
149149
$cacheName = "NonExistingRedisCache"
150150
$location = "North Central US"
151151

@@ -161,7 +161,7 @@ function Test-RedisCachePipeline
161161
{
162162
# Setup
163163
# resource group should exists
164-
$resourceGroupName = "MyResourceGroup"
164+
$resourceGroupName = "SunnyAAPT6"
165165
$cacheName = "powershelltestpipe"
166166
$location = "North Central US"
167167

@@ -247,7 +247,7 @@ function Test-SetRedisCacheBugFixTest
247247
{
248248
# Setup
249249
# resource group should exists
250-
$resourceGroupName = "siddharth"
250+
$resourceGroupName = "SunnyAAPT6"
251251
$cacheName = "siddharthchatrola"
252252
$location = "North Central US"
253253

@@ -284,7 +284,7 @@ function Test-RedisCacheClustering
284284
{
285285
# Setup
286286
# resource group should exists
287-
$resourceGroupName = "MyResourceGroup"
287+
$resourceGroupName = "SunnyAAPT6"
288288
$cacheName = "powershellcluster"
289289
$location = "East US"
290290

@@ -393,4 +393,34 @@ function Test-RedisCacheClustering
393393

394394
# Delete cache
395395
Assert-True {Remove-AzureRmRedisCache -ResourceGroupName $resourceGroupName -Name $cacheName -Force -PassThru} "Remove cache failed."
396+
}
397+
398+
<#
399+
.SYNOPSIS
400+
Tests SetAzureRedisCacheDiagnostics
401+
#>
402+
function Test-SetAzureRedisCacheDiagnostics
403+
{
404+
# Setup
405+
# resource group should exists
406+
$resourceGroupName = "SunnyAAPT6"
407+
$cacheName = "sunnycache"
408+
409+
# Set Diagnostics
410+
Set-AzureRmRedisCacheDiagnostics -ResourceGroupName $resourceGroupName -Name $cacheName -StorageAccountId "/subscriptions/f8f8f139-2fd5-4d86-afca-21f21f35806e/resourceGroups/SunnyAAPT6/providers/Microsoft.ClassicStorage/storageAccounts/sunnystoragenew"
411+
}
412+
413+
<#
414+
.SYNOPSIS
415+
Tests RemoveAzureRedisCacheDiagnostics
416+
#>
417+
function Test-RemoveAzureRedisCacheDiagnostics
418+
{
419+
# Setup
420+
# resource group should exists
421+
$resourceGroupName = "SunnyAAPT6"
422+
$cacheName = "sunnycache"
423+
424+
# Set Diagnostics
425+
Remove-AzureRmRedisCacheDiagnostics -ResourceGroupName $resourceGroupName -Name $cacheName -Force
396426
}

src/ResourceManager/RedisCache/Commands.RedisCache.Test/ScenarioTests/RedisCacheTestsBase.cs

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ namespace Microsoft.Azure.Commands.RedisCache.Test.ScenarioTests
2020
using Microsoft.Azure.Management.Redis;
2121
using Microsoft.Azure.Common.Authentication;
2222
using WindowsAzure.Commands.Test.Utilities.Common;
23+
using Microsoft.Azure.Management.Insights;
24+
using Microsoft.Azure.Management.Internal.Resources;
2325

2426
public abstract class RedisCacheTestsBase : RMTestBase, IDisposable
2527
{
@@ -32,8 +34,11 @@ protected RedisCacheTestsBase()
3234

3335
protected void SetupManagementClients()
3436
{
35-
var redisManagementClient = GetRedisManagementClient();
36-
helper.SetupManagementClients(redisManagementClient);
37+
object[] managementClients = new object[3];
38+
managementClients[0] = GetRedisManagementClient();
39+
managementClients[1] = GetInsightsManagementClient();
40+
managementClients[2] = GetResourceManagementClient();
41+
helper.SetupManagementClients(managementClients);
3742
}
3843

3944
protected void RunPowerShellTest(params string[] scripts)
@@ -59,6 +64,16 @@ protected RedisManagementClient GetRedisManagementClient()
5964
return TestBase.GetServiceClient<RedisManagementClient>(new CSMTestEnvironmentFactory());
6065
}
6166

67+
protected InsightsManagementClient GetInsightsManagementClient()
68+
{
69+
return TestBase.GetServiceClient<InsightsManagementClient>(new CSMTestEnvironmentFactory());
70+
}
71+
72+
protected ResourceManagementClient GetResourceManagementClient()
73+
{
74+
return TestBase.GetServiceClient<ResourceManagementClient>(new CSMTestEnvironmentFactory());
75+
}
76+
6277
public void Dispose()
6378
{
6479
}

0 commit comments

Comments
 (0)