public void SetupTest() { clientMock = new Mock<ICloudServiceClient>(); clientMock.Setup(f => f.RemoveCloudService(serviceName)); commandRuntimeMock = new Mock<ICommandRuntime>(); commandRuntimeMock.Setup(f => f.WriteObject(true)); commandRuntimeMock.Setup(f => f.ShouldProcess(It.IsAny<string>(), It.IsAny<string>())).Returns(true); removeAzureServiceCmdlet = new RemoveAzureServiceCommand() { CloudServiceClient = clientMock.Object, CommandRuntime = commandRuntimeMock.Object }; }
public void SetupTest() { GlobalPathInfo.GlobalSettingsDirectory = Data.AzureSdkAppDir; CmdletSubscriptionExtensions.SessionManager = new InMemorySessionManager(); mockCommandRuntime = new MockCommandRuntime(); channel = new SimpleServiceManagement(); removeServiceCmdlet = new RemoveAzureServiceCommand(channel) { ShareChannel = true }; removeServiceCmdlet.CommandRuntime = mockCommandRuntime; }