示例#1
0
        public void ModifyContent_WithValid_ReturnsString(string toRemove, string toModify, string expected)
        {
            var action = new RemoveStringContentAction(toRemove);
            var result = action.ModifyContent(toModify);

            Assert.Equal(expected, result);
        }
示例#2
0
        public void ModifyContent_WithEmptyToReplace_ThrowsArgumentException()
        {
            var action = new RemoveStringContentAction("");

            Assert.Throws <ArgumentException>(() => action.ModifyContent("[Example String]"));
        }
示例#3
0
        public void ModifyContent_WithNullParameter_ThrowsArgumentException()
        {
            var action = new RemoveStringContentAction(null);

            Assert.Throws <ArgumentException>(() => action.ModifyContent("[Example String]"));
        }