public void ShouldReturnAmendedValueWithNoAmperstand()
        {
            // Arrange
            // Act
            var result = _sut.ApplyConvention("Bower&Wilkins!");

            // Assert
            Assert.Equal("BowernWilkins!", result);
        }
        private bool TryMatchCellValue(IDataSheetCell c)
        {
            var cellValue      = c.GetValue <string>();
            var searchCriteria = _convention.ApplyConvention(cellValue);
            var result         =
                string.Compare(searchCriteria, _valueToFind, _options) == 0;

            return(result);
        }
示例#3
0
        public void ShouldRemoveAllSpecialSymbols()
        {
            // Arrange
            var sourceValue = "1report!\"£$%^ &*()    _ += -`¬;:'@#~/?.>   ,<\\|admin1";

            // Act
            var result = _sut.ApplyConvention(sourceValue);

            // Assert
            Assert.Equal("1reportadmin1", result);
        }