Beispiel #1
0
        public ApiResult <Object> RemoveConfiguration(string name)
        {
            var cmd = new RemoveInputConfiguration(inputConfigProvider, storageProvider, name);

            cmd.Execute();
            return(cmd.Result);
        }
        public void ReturnsResultWhenNotFound()
        {
            cmd = new RemoveInputConfiguration(inputConfigProvider, storageProvider, notFoundConfig.Name);
            cmd.Execute();
            var result = cmd.Result;

            Assert.IsNotNull(result);
            Assert.IsNotNull(result.Content);
            Assert.IsFalse(result.Success);
            inputConfigProviderMock.Verify(f => f.FindConfigForName(It.Is<string>(s => s.Equals(notFoundConfig.Name))), Times.Once);
        }
Beispiel #3
0
        public void ReturnsResultWhenNotFound()
        {
            cmd = new RemoveInputConfiguration(inputConfigProvider, storageProvider, notFoundConfig.Name);
            cmd.Execute();
            var result = cmd.Result;

            Assert.IsNotNull(result);
            Assert.IsNotNull(result.Content);
            Assert.IsFalse(result.Success);
            inputConfigProviderMock.Verify(f => f.FindConfigForName(It.Is <string>(s => s.Equals(notFoundConfig.Name))), Times.Once);
        }
Beispiel #4
0
 public ApiResult<Object> RemoveConfiguration(string name)
 {
     var cmd = new RemoveInputConfiguration(inputConfigProvider, storageProvider, name);
     cmd.Execute();
     return cmd.Result;
 }