StringToField() public method

public StringToField ( string from ) : object
from string
return object
Exemplo n.º 1
0
        public void To_transaction_code()
        {
            // Arrange
            var c = new EnumConverter(typeof(TransactionCode));

            // Act
            var result = c.StringToField("50");

            // Assert
            Assert.AreEqual(TransactionCode.CreditItem, result);
        }
Exemplo n.º 2
0
        public void To_indicator()
        {
            // Arrange
            var c = new EnumConverter(typeof(Indicator));

            // Act
            var result = c.StringToField("X");

            // Assert
            Assert.AreEqual(Indicator.DividendPaid, result);
        }