示例#1
0
        public void Should_Remove_AllWhiteSpace()
        {
            var input    = "   I    +    I    ";
            var expected = "I + I";

            Assert.AreEqual(expected, InputCleaner.Clean(input));
        }
示例#2
0
        public void Passing_Null_Gives_Empty_String()
        {
            string input    = null;
            var    expected = string.Empty;

            Assert.AreEqual(expected, InputCleaner.Clean(input));
        }
示例#3
0
        public static void Main(string[] args)
        {
            string expression = string.Empty;

            if (args.Length > 0)
            {
                expression = InputCleaner.Clean(args[0]);
                Console.WriteLine("{0}", new RomanCalculator(expression).Result());
            }
            else
            {
                Console.WriteLine("usage: Calc I + I");
            }
        }