예제 #1
0
        public void ConvertToNewNumeralSystem_Value_ExpectCorrectConvert(int accepted, int exception, string result)
        {
            NumberConverter numberConverter = new NumberConverter(accepted, exception);
            StringBuilder   actual          = numberConverter.ConvertToNewNumeralSystem();

            Assert.AreEqual(result, actual);
        }
예제 #2
0
        public void ConvertToNewNumeralSystem_NotValidNumbers_ExpectExceptions(int acceptedNumber, int ecceptedFoundetion)
        {
            NumberConverter numberConverter = new NumberConverter(acceptedNumber, ecceptedFoundetion);

            Assert.Throws <Exception>
            (
                () => numberConverter.ConvertToNewNumeralSystem()
            );
        }