Пример #1
0
        public void AddingSingleNumber_ReturnsThatNumber()
        {
            var parser     = new FakeParser();
            var storage    = new FakeStorage();
            var calculator = new Calculator(parser, storage);
            var result     = calculator.Add("1");

            Assert.Equal(1, result);
        }
Пример #2
0
        public void AddingEmptySet_ReturnsZero()
        {
            var parser     = new FakeParser();
            var storage    = new FakeStorage();
            var calculator = new Calculator(parser, storage);
            var result     = calculator.Add("");

            Assert.Equal(0, result);
        }