|
| 1 | +// ---------------------------------------------------------------------------------- |
| 2 | +// |
| 3 | +// Copyright Microsoft Corporation |
| 4 | +// Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | +// you may not use this file except in compliance with the License. |
| 6 | +// You may obtain a copy of the License at |
| 7 | +// http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | +// Unless required by applicable law or agreed to in writing, software |
| 9 | +// distributed under the License is distributed on an "AS IS" BASIS, |
| 10 | +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 11 | +// See the License for the specific language governing permissions and |
| 12 | +// limitations under the License. |
| 13 | +// ---------------------------------------------------------------------------------- |
| 14 | + |
| 15 | +namespace Microsoft.Azure.Commands.ResourceManager.Automation.Test.ScenarioTests.UpdateManagement |
| 16 | +{ |
| 17 | + using Microsoft.Azure.Commands.Automation.Test; |
| 18 | + using Microsoft.WindowsAzure.Commands.ScenarioTest; |
| 19 | + using Xunit; |
| 20 | + |
| 21 | + public class UpdateManagementTests : AutomationScenarioTestsBase |
| 22 | + { |
| 23 | + public UpdateManagementTests(Xunit.Abstractions.ITestOutputHelper output) |
| 24 | + { |
| 25 | + ServiceManagemenet.Common.Models.XunitTracingInterceptor.AddToContext(new ServiceManagemenet.Common.Models.XunitTracingInterceptor(output)); |
| 26 | + } |
| 27 | + |
| 28 | + [Fact] |
| 29 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 30 | + [Trait(Category.Service, Category.Automation)] |
| 31 | + public void CreateWindowsOneTimeSUCWithDefaults() |
| 32 | + { |
| 33 | + RunPowerShellTest("Test-CreateWindowsOneTimeSoftwareUpdateConfigurationWithDefaults"); |
| 34 | + } |
| 35 | + |
| 36 | + [Fact] |
| 37 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 38 | + [Trait(Category.Service, Category.Automation)] |
| 39 | + public void CreateLinuxOneTimeSUCWithDefaults() |
| 40 | + { |
| 41 | + RunPowerShellTest("Test-CreateLinuxOneTimeSoftwareUpdateConfigurationWithDefaults"); |
| 42 | + } |
| 43 | + |
| 44 | + [Fact] |
| 45 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 46 | + [Trait(Category.Service, Category.Automation)] |
| 47 | + public void CreateWindowsOneTimeSUCWithAllOption() |
| 48 | + { |
| 49 | + RunPowerShellTest("Test-CreateWindowsOneTimeSoftwareUpdateConfigurationWithAllOption"); |
| 50 | + } |
| 51 | + |
| 52 | + [Fact] |
| 53 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 54 | + [Trait(Category.Service, Category.Automation)] |
| 55 | + public void CreateLinuxOneTimeSUCWithAllOption() |
| 56 | + { |
| 57 | + RunPowerShellTest("Test-CreateLinuxOneTimeSoftwareUpdateConfigurationWithAllOption"); |
| 58 | + } |
| 59 | + |
| 60 | + [Fact] |
| 61 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 62 | + [Trait(Category.Service, Category.Automation)] |
| 63 | + public void CreateLinuxOneTimeSUCNonAzureOnly() |
| 64 | + { |
| 65 | + RunPowerShellTest("Test-CreateLinuxOneTimeSoftwareUpdateConfigurationNonAzureOnly"); |
| 66 | + } |
| 67 | + |
| 68 | + [Fact(Skip = "No recording generated")] |
| 69 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 70 | + [Trait(Category.Service, Category.Automation)] |
| 71 | + public void CreateLinuxOneTimeSUCNoTarget() |
| 72 | + { |
| 73 | + RunPowerShellTest("Test-CreateLinuxOneTimeSoftwareUpdateConfigurationNoTargets"); |
| 74 | + } |
| 75 | + |
| 76 | + [Fact] |
| 77 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 78 | + [Trait(Category.Service, Category.Automation)] |
| 79 | + public void GetAllSUCs() |
| 80 | + { |
| 81 | + RunPowerShellTest("Test-GetAllSoftwareUpdateConfigurations"); |
| 82 | + } |
| 83 | + |
| 84 | + [Fact] |
| 85 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 86 | + [Trait(Category.Service, Category.Automation)] |
| 87 | + public void GetAllSUCsForVM() |
| 88 | + { |
| 89 | + RunPowerShellTest("Test-GetSoftwareUpdateConfigurationsForVM"); |
| 90 | + } |
| 91 | + |
| 92 | + [Fact] |
| 93 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 94 | + [Trait(Category.Service, Category.Automation)] |
| 95 | + public void DeleteSUC() |
| 96 | + { |
| 97 | + RunPowerShellTest("Test-DeleteSoftwareUpdateConfiguration"); |
| 98 | + } |
| 99 | + |
| 100 | + [Fact] |
| 101 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 102 | + [Trait(Category.Service, Category.Automation)] |
| 103 | + public void GetAllRuns() |
| 104 | + { |
| 105 | + RunPowerShellTest("Test-GetAllSoftwareUpdateRuns"); |
| 106 | + } |
| 107 | + |
| 108 | + [Fact] |
| 109 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 110 | + [Trait(Category.Service, Category.Automation)] |
| 111 | + public void GetAllRunsWithFilters() |
| 112 | + { |
| 113 | + RunPowerShellTest("Test-GetAllSoftwareUpdateRunsWithFilters"); |
| 114 | + } |
| 115 | + |
| 116 | + [Fact] |
| 117 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 118 | + [Trait(Category.Service, Category.Automation)] |
| 119 | + public void GetAllRunsWithFiltersNoResults() |
| 120 | + { |
| 121 | + RunPowerShellTest("Test-GetAllSoftwareUpdateRunsWithFiltersNoResults"); |
| 122 | + } |
| 123 | + |
| 124 | + [Fact] |
| 125 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 126 | + [Trait(Category.Service, Category.Automation)] |
| 127 | + public void GetAllMachineRuns() |
| 128 | + { |
| 129 | + RunPowerShellTest("Test-GetAllSoftwareUpdateMachineRuns"); |
| 130 | + } |
| 131 | + |
| 132 | + [Fact] |
| 133 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 134 | + [Trait(Category.Service, Category.Automation)] |
| 135 | + public void GetAllMachineRunsWithFilters() |
| 136 | + { |
| 137 | + RunPowerShellTest("Test-GetAllSoftwareUpdateMachineRunsWithFilters"); |
| 138 | + } |
| 139 | + |
| 140 | + [Fact] |
| 141 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 142 | + [Trait(Category.Service, Category.Automation)] |
| 143 | + public void GetAllMachineRunsWithFiltersNoResults() |
| 144 | + { |
| 145 | + RunPowerShellTest("Test-GetAllSoftwareUpdateMachineRunsWithFiltersNoResults"); |
| 146 | + } |
| 147 | + |
| 148 | + [Fact] |
| 149 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 150 | + [Trait(Category.Service, Category.Automation)] |
| 151 | + public void CreateLinuxWeeklySUC() |
| 152 | + { |
| 153 | + RunPowerShellTest("Test-CreateLinuxWeeklySoftwareUpdateConfiguration"); |
| 154 | + } |
| 155 | + |
| 156 | + [Fact] |
| 157 | + [Trait(Category.AcceptanceType, Category.CheckIn)] |
| 158 | + [Trait(Category.Service, Category.Automation)] |
| 159 | + public void CreateWindowsMonthlySUC() |
| 160 | + { |
| 161 | + RunPowerShellTest("Test-CreateWindowsMonthlySoftwareUpdateConfiguration"); |
| 162 | + } |
| 163 | + } |
| 164 | +} |
0 commit comments